mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-15 08:48:52 +00:00
Fix to #360 - Updated the general generator (Java/C#) to emit fully qualified names where the referenced object isn't directly in this namespace. Added test fbs files to verify compilation.
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
<?php
|
||||
// automatically generated, do not modify
|
||||
|
||||
namespace NamespaceA\NamespaceB;
|
||||
|
||||
class EnumInNestedNS
|
||||
{
|
||||
const A = 0;
|
||||
const B = 1;
|
||||
const C = 2;
|
||||
|
||||
private static $names = array(
|
||||
"A",
|
||||
"B",
|
||||
"C",
|
||||
);
|
||||
|
||||
public static function Name($e)
|
||||
{
|
||||
if (!isset(self::$names[$e])) {
|
||||
throw new \Exception();
|
||||
}
|
||||
return self::$names[$e];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user