Recent

Author Topic: In pascal multiple line string possible  (Read 3331 times)

MarkMLl

  • Hero Member
  • *****
  • Posts: 8080
Re: In pascal multiple line string possible
« Reply #30 on: December 01, 2024, 09:44:04 am »
For code fragments moving them to a separate file has the advantage that an IDE can easily syntax highlight them or provide refactoring features. With code embedded as part of other code this becomes harder.

I don't think it's reasonable to design a language with the express intention of making it easy for IDEs. Declarations/definitions should be relatively close to the location at which they're used, and forcing a reader/maintainer to consult material in a separate file is as bad as forcing him to flip back to the top of the current one: and almost as bad as allowing such things to be added as footnotes after the point at which they're used.

My own opinion is that there is no need for an embedded fragment to be highlighted as anything other than an alien syntax or for the content to be refactored, in the same way that there is no need for the IDE to offer a debugger for it: it's reasonable to expect the writer to have debugged it elsewhere (although a substantial number of SQL queries in this forum quite obviously haven't been). But in any case this isn't the 1970s any more, and a development environment will happily open multiple files and display each in multiple contexts.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

 

TinyPortal © 2005-2018