forked from OSchip/llvm-project
Updated the LLDB rvalue reference test to cross-reference with a bugzilla report,
provide more detail on compiler compatibility, and to illustrate that this is an issue with expression evaluation. - Note that clang doesn't emit DW_TAG_const_type, which might be okay if there's no such thing as a non-const rvalue reference. How about foo(make_int())? llvm-svn: 187499
This commit is contained in:
parent
abd96a0c0a
commit
dea0e6326b
|
@ -6,7 +6,7 @@ import lldb
|
||||||
from lldbtest import *
|
from lldbtest import *
|
||||||
import lldbutil
|
import lldbutil
|
||||||
|
|
||||||
class CPPThisTestCase(TestBase):
|
class RvalueReferencesTestCase(TestBase):
|
||||||
|
|
||||||
mydir = os.path.join("lang", "cpp", "rvalue-references")
|
mydir = os.path.join("lang", "cpp", "rvalue-references")
|
||||||
|
|
||||||
|
@ -20,8 +20,9 @@ class CPPThisTestCase(TestBase):
|
||||||
self.static_method_commands()
|
self.static_method_commands()
|
||||||
|
|
||||||
#rdar://problem/11479676
|
#rdar://problem/11479676
|
||||||
@expectedFailureClang
|
@expectedFailureClang # pr16762: Expression evaluation of an rvalue-reference does not show the correct type.
|
||||||
@expectedFailureGcc # GCC (4.7) does not emit correct DWARF tags for rvalue-references
|
@expectedFailureGcc # GCC (4.7) does not emit correct DWARF tags for rvalue-references
|
||||||
|
@expectedFailureIcc # ICC (13.1, 14-beta) do not emit DW_TAG_rvalue_reference_type.
|
||||||
@dwarf_test
|
@dwarf_test
|
||||||
def test_with_dwarf_and_run_command(self):
|
def test_with_dwarf_and_run_command(self):
|
||||||
"""Test that rvalues are supported in the C++ expression parser"""
|
"""Test that rvalues are supported in the C++ expression parser"""
|
||||||
|
@ -43,8 +44,14 @@ class CPPThisTestCase(TestBase):
|
||||||
|
|
||||||
self.runCmd("process launch", RUN_SUCCEEDED)
|
self.runCmd("process launch", RUN_SUCCEEDED)
|
||||||
|
|
||||||
|
# Note that clang as of r187480 doesn't emit DW_TAG_const_type, unlike gcc 4.8.1
|
||||||
|
# With gcc 4.8.1, lldb reports the type as (int &&const)
|
||||||
|
self.expect("frame variable i",
|
||||||
|
startstr = "(int &&",
|
||||||
|
substrs = ["i = 0x", "&i = 3"])
|
||||||
|
|
||||||
self.expect("expression -- i",
|
self.expect("expression -- i",
|
||||||
startstr = "(int &&) $0 =",
|
startstr = "(int &&",
|
||||||
substrs = ["3"])
|
substrs = ["3"])
|
||||||
|
|
||||||
self.expect("breakpoint delete 1")
|
self.expect("breakpoint delete 1")
|
||||||
|
|
Loading…
Reference in New Issue