Wiki source for KeyPgDdfblang


Show raw source

{{fbdoc item="title" value="__FB_LANG__"}}----
Intrinsic define (macro value) set by the compiler

{{fbdoc item="syntax"}}##
""__FB_LANG__""
##
{{fbdoc item="desc"}}
##""__FB_LANG__""## indicates which language compatibility option was set at the time of compilation of a module. By default ##""__FB_LANG__""## will be set to ##"fb"##. The language compatibility option can be changed using one (or more) of the following methods:
- //[[CompilerOptlang|-lang]]// command line option
- //[[CompilerOptforcelang|-forcelang]]// command line option
- ##[[KeyPgPplang|#lang]]## directive
- ##[[KeyPgMetaLang|$lang]]## metacommand

Returns a lower case string with one of the following values:
{{table columns="2" cellpadding="1" cells="value;description;''fb'';FreeBASIC compatibility (default);''qb'';QBASIC compatibility;''fblite'';FreeBASIC language compatibility, with a more QBASIC-compatible coding style;''deprecated'';FBC version 0.16 compatibility"}}

##""__FB_LANG__""## is always defined.

{{fbdoc item="ex"}}
{{fbdoc item="filename" value="examples/manual/defines/fblang.bas"}}%%(freebasic)
'' Set option explicit always on

#ifdef __FB_LANG__
#if __FB_LANG__ <> "fb"
Option Explicit
#endif
#else
'' Older version - before lang fb
Option Explicit
#endif
%%

{{fbdoc item="diff"}}
- New to ""FreeBASIC""

{{fbdoc item="see"}}
- ##[[KeyPgDdfbversion|__FB_VERSION__]]##
- ##[[KeyPgPplang|#lang]]##
- [[CompilerOptlang|Compiler Option: -lang]]
- [[CompilerOptforcelang|Compiler Option: -forcelang]]
- [[CompilerDialects|Compiler Dialects]]

{{fbdoc item="back" value="CatPgDddefines|Intrinsic Defines"}}
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki



sf.net phatcode