OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [cpp0x/] [udlit-inline.C] - Blame information for rev 774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// { dg-options "-std=c++0x" }
2
 
3
//  Literal operators can be inline.
4
 
5
inline int
6
operator"" _thing1(char cc)
7
{ return 42 * cc; }
8
 
9
int operator"" _thing2(char cc);
10
 
11
class Foo
12
{
13
  int
14
  friend operator"" _thing2(char cc)
15
  { return 42 * cc; }
16
};
17
 
18
int i = operator"" _thing1('x');
19
int j = 'x'_thing1;
20
 
21
int iF = operator"" _thing2('x');
22
int jF = 'x'_thing2;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.