Skip to content

Commit

Permalink
Update slang-ast-decl-ref.cpp (shader-slang#5786)
Browse files Browse the repository at this point in the history
  • Loading branch information
saipraveenb25 authored Dec 6, 2024
1 parent 27b7ac0 commit 0d5636c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions source/slang/slang-ast-decl-ref.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,10 @@ void DeclRefBase::toText(StringBuilder& out)
List<Decl*> decls;
for (auto dd = getDecl(); dd; dd = dd->parentDecl)
{
// Skip the top-level decl.
if (as<ModuleDecl>(dd))
// Skip the module, file & include decls since their names are
// considered "transparent"
//
if (as<ModuleDecl>(dd) || as<FileDecl>(dd) || as<IncludeDecl>(dd))
continue;

// Skip base decls in generic containers. We will handle them when we handle the generic
Expand Down

0 comments on commit 0d5636c

Please sign in to comment.