http://llvm.org/bugs/show_bug.cgi?id=19692
Bug ID: 19692
Summary: transitive module define/undefine not quite right
Product: clang
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Modules
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected]
Classification: Unclassified
Suppose we have:
module cstd.stdint:
#define INT64_MAX 42
module LLVMSupport.Blah:
#include "stdint.h"
module LLVMSupport.AIXDataTypesFix
#undef INT64_MAX
module LLVMTarget.Blah:
import LLVMSupport.Blah;
int use = INT64_MAX;
module LLVMTarget.Foo:
// stuff
my.cc:
import LLVMTarget.Foo
import stdint
int k = INT64_MAX; // error!
We reject the last line because we can't find a definition of INT64_MAX. What
went wrong here is that LLVM_Target emitted the IdentifierInfo data for
'INT64_MAX' but didn't include the overriding information for imported macro
definitions, and we didn't look into LLVMSupport nor into cstd when looking for
the macro because they're transitively imported by LLVMTarget.
=> We need to re-export the visibility and overriding information when we
re-export another module file's macro definitions.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs