Changeset 545d679 in tol


Ignore:
Timestamp:
Mar 3, 2009, 9:38:16 AM (18 years ago)
Author:
Víctor de Buen <vdebuen@…>
Branches:
1941-docker-image-to-test, devel, master
Children:
46c93bf
Parents:
994e0b6
Message:

Using CppFile() to get source path for built-in functions

git-svn-id: ​https://www.tol-project.org/svn/tolp/trunk@683 be4846ae-f051-483a-831f-b64e7d08527f

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tol/btol/bgrammar/syn.cpp

    r994e0b6 r545d679  
    282282{
    283283  TRACE_MEMORY_SHOW(this,"BSyntaxObject::SourcePath");
    284   if(!BSourcePath::IsAlive(sourcePath_)) { return(BSyntaxObject::CBTextNullRef()); }
    285   else                                   { return(sourcePath_->Name()); }
     284  if(sourcePath_ && BSourcePath::IsAlive(sourcePath_))
     285  {
     286    return(sourcePath_->Name());
     287  }
     288  else if(System() && Mode()==BBUILTINFUNMODE)
     289  {
     290    BOperator* opr = (BOperator*)this;
     291    return(opr->CppFile());
     292  }
     293  else if(System() && (Mode()==BOBJECTMODE) && (Grammar()==GraCode()))
     294  {
     295    BUserCode* uCode = (BUserCode*)this;
     296    return(uCode->Contens().Operator()->CppFile());
     297  }
     298  else
     299  {
     300    return(BSyntaxObject::CBTextNullRef());
     301  }
    286302}
    287303
Note: See TracChangeset for help on using the changeset viewer.