FYI Lucee 6 now supports internal components, so you can do
susi=new component {
this.name="Susi"
function getName() {
return this.name;
}
}
FYI Lucee 6 now supports internal components, so you can do
susi=new component {
this.name="Susi"
function getName() {
return this.name;
}
}
Initially I was sceptical about this, and - in what I think is a first - was pretty much in agreement with @isapir here. No offence Igal, you know what I mean
However I had a conversation with @seancorfield about all this, and the most valuable takeaway from it is Records, and Data classes | Kotlin Documentation. So thereâs precedent out there.
Still⌠in the CFML context⌠kinda thinking this is a solution looking for problem. And if the issue is with there being a perception objects are still slow, then deal with that directly. I liked @bdw429sâs assessment of this.
And, Iâll repeat this from another thread. Weâve just had all the excitement of Lucee 6 being done and out the door. I canât help but think a better use of development time ATM would be fixing bugs (I highlighted the 100-odd critical bugs in Jira ATM. Just to filter down from the 1000-odd open bugs in total). There might be some scope for play time later, closer to when/if Lucee 7 comes out. For now I think technical debt recovery might be a better application of pplâs effortsâŚ
I mean it might be thankless and uninteresting, but the issues in Jira represent actual things that are preventing ppl from doing what they are trying to do right now. Letâs look @ âright nowâ, not some speculative future.
In fact, maybe we could just use FW1âs implementation of the Bean. Why reinvent the wheel, when the functionality has already been tried & tested, for many years?
I like the idea of smart structs. Did the ideas above turn into any actually features besides inline components?
In my code I create structs to move data around the system. Structs are fast and convenient. Currently I enforce nodes by just making sure I always create them which works because I am a 1 person team. It would be great if there was some interface type system where I could define the blueprint of my structs. I could create components to make it works. The reasons I didnât initially was components were slow. Yes I go all the way back to ColdFusion 4.5 days. While today components are much faster I still like the easy of using structs.
I want a struct that has a blueprint and is as fast as possible. I donât use getters or setters currently as I keep my code separate from my data. While not the way most people develop code today. It works for me and is fast.