http://llvm.org/bugs/show_bug.cgi?id=11310

             Bug #: 11310
           Summary: const pointers to instances is allowed to modify the
                    instance it points
           Product: new-bugs
           Version: unspecified
          Platform: PC
        OS/Version: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]
    Classification: Unclassified


Created attachment 7575
  --> http://llvm.org/bugs/attachment.cgi?id=7575
example showing that the const pointers are allowed to modify the instance it
points to

It happens in the following 2 cases:
1) even if you explicitly specify the class type and specify "const"
2) when you you "cons id" as the data type

Overview
=======
const pointer should not be allowed to be modify the instance it points to

Actual Behavior
============
const pointer is allowed to be modify the instance it points to

Expected Behavior
=============
const pointer shouldn't be allowed to be modify the instance it points to.

Example:
========
The example attached shows the 3 cases of using const pointers.
In 2 cases, no error is thrown and in 1 case error is thrown and seems
inconsistent

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- 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

Reply via email to