Recent

Author Topic: [SOLVED]Are there some pre-defined variables such as __line__ like C languange ?  (Read 1637 times)

kinlion

  • Jr. Member
  • **
  • Posts: 82
  • I Love Lazarus
These variables are useful.
For examples:
  __build_time__ can be shown to indicate whethor the exe-file is the latest version. (The version number is not well-understood to none-programmer).
  __file__, __line__ can be used in debug out for convinent.
« Last Edit: December 08, 2018, 07:48:20 am by kinlion »

marcov

  • Administrator
  • Hero Member
  • *
  • Posts: 11383
  • FPC developer.
Re: Are there some pre-defined variables such as __line__ like C languange ?
« Reply #1 on: December 07, 2018, 08:31:51 am »
Yes, they are documented in the manual: https://www.freepascal.org/docs-html/prog/progsu41.html

Afaik the next release will have some more. Those are not yet in the above list.

kinlion

  • Jr. Member
  • **
  • Posts: 82
  • I Love Lazarus
Re: Are there some pre-defined variables such as __line__ like C languange ?
« Reply #2 on: December 07, 2018, 04:38:15 pm »
Yes, they are documented in the manual: https://www.freepascal.org/docs-html/prog/progsu41.html

Afaik the next release will have some more. Those are not yet in the above list.

Thanks a lot. That's very useful.

 

TinyPortal © 2005-2018