August 2, 2023
Disable Optional Semicolons in CF2021
Comments
(5)
August 2, 2023
Disable Optional Semicolons in CF2021
Newbie 1 posts
Followers: 0 people
(5)

Hi,

Is it possible to disable optional semicolons in CF2021? We run CF2016 in our live environment, but I develop on CF2021 in anticipation of upgrading, but I occasionally get caught out by missing semicolons, which work locally but obviously don’t when pushed to the live server.

Thanks,
Geoff

5 Comments
2024-04-19 13:50:00
2024-04-19 13:50:00

Personally, I don’t know how you guys think of this.

I think a professional programmer won’t miss the semicolons.

Because the tradition of adding semicolons as delimeters comes from C.

C is one of the essential milestones of computer industry and academic.

If you are a beginner and are ambitious to be occupational or more advanced, I suggest that you might adapt to this habits and not to think of how to disable this feature.

Like
(3)
>
Steven Yang Drinks Coffee
's comment
2024-04-19 15:29:33
2024-04-19 15:29:33
>
Steven Yang Drinks Coffee
's comment

Steven, I think Geoff presented his use case pretty clearly. It’s not so much a preference issue in that scenario, so the historical context doesn’t help solve his problem. 🙂 He’s bumping into cf2016 requiring it while running code in both that and later cf versions at the same time.

Still the use case is an aging one: Adobe stopped supporting cf2016 in 2021, and as such I’d think that if they’ve not accommodated this (reasonable) scenario by now, I doubt they’d ever accommodate it.

Like
>
Charlie Arehart
's comment
2024-04-19 15:59:06
2024-04-19 15:59:06
>
Charlie Arehart
's comment

In my opinion, I think he can add the semicolons manually when it tells him that is incompatible if the mistakes were NOT SUPER-LARGE.

I often download and use thiry-party components at my work as well. And occassionally, I’ll have to debug for the original author with editing the source-code or extend its functions when I needed. ‘Coz I don’t have choice. If I can’t complete my work, I will probably be fired.

Sometimes the components could be bad fruits.

So it’s not a very severe things. Is there any alternatives or remedies available?

BTW, the mood of the CF staff is not stable!!! To be aware of the historical context is necessary. I don’t mean to argue about this opinion for myself. And there isn’t a mature mechenism in CF to solve the issues of compatibility.

I insist a piece of philosophy that if it can run, and the infrastructure and dependencies should be never updated except it occurs to be urgent. I learned it from Japanese’s software management.

Hope that useful to you.

Like
>
Steven Yang Drinks Coffee
's comment
2024-04-20 01:40:44
2024-04-20 01:40:44
>
Steven Yang Drinks Coffee
's comment

I’ll tap out on this.

Like
2023-08-04 16:45:42
2023-08-04 16:45:42

Semicolons became optional in CF2018. What’s odd is that they are sometimes required to reduce ambiguity.
https://coldfusion.adobe.com/2018/07/writing-cfms-without-semicolons/

This issue occasionally happens to me, but I fear that disabling semicolons and then integrating modern third-party CFCs, UDFs & libraries in the future would not work.  I’ve been using CommandBox & TestBox to spin up different CFML servers to test code written on CF2021 to ensure that it’s both backwards as well as cross-compatible with Lucee CFML.

CROSS-COMPATIBILITY NOTE: A feature to “require semicolons” was requested for Lucee back in 2015 and was rejected. More info at https://luceeserver.atlassian.net/browse/LDEV-369

Like
Add Comment