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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [ext/] [pr34829.C] - Blame information for rev 693

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 693 jeremybenn
// Test for PR c++/34829
2
// Placement new should be ok for non-aggregate Java types.
3
 
4
// { dg-do compile }
5
// { dg-options "" }
6
 
7
extern "Java"
8
{
9
  typedef __java_byte jbyte;
10
}
11
 
12
typedef __SIZE_TYPE__ size_t;
13
 
14
void *operator new (size_t, void *m)
15
{
16
  return m;
17
}
18
 
19
jbyte *f(void *memory)
20
{
21
  return new (memory) jbyte;
22
}

powered by: WebSVN 2.1.0

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