the foundations of a type traits module; better error messages for expr, typedesc and typeclasses params

This commit is contained in:
Zahary Karadjov 2012-04-06 05:02:48 +03:00
commit efb53233cb
8 changed files with 65 additions and 12 deletions

View file

@ -243,8 +243,13 @@ const
sfFakeConst* = sfDeadCodeElim # const cannot be put into a data section
sfDispatcher* = sfDeadCodeElim # copied method symbol is the dispatcher
sfNoInit* = sfMainModule # don't generate code to init the variable
sfImmediate* = sfDeadCodeElim # macro or template is immediately expanded
# without considering any possible overloads
sfAnon* = sfCompilerProc # symbol name that was generated by the compiler
# the compiler will avoid printing such names
# in user messages.
const
# getting ready for the future expr/stmt merge
@ -358,7 +363,8 @@ const
type
TMagic* = enum # symbols that require compiler magic:
mNone, mDefined, mDefinedInScope, mLow, mHigh, mSizeOf, mIs, mOf,
mNone,
mDefined, mDefinedInScope, mLow, mHigh, mSizeOf, mTypeTrait, mIs, mOf,
mEcho, mShallowCopy, mSlurp,
mParseExprToAst, mParseStmtToAst, mExpandToAst,
mUnaryLt, mSucc,