Skip to content

Java long constants convert to C# int #6

@shimmerkopf

Description

@shimmerkopf

Hi there!

With -allowlong option active, the following Java code:


public class Foo
{
    public long bar(int n)
    {
        return 1L << n;
    }
}

is converted to C#:


public class Foo: object
{
    public Foo():base()
    {
    }

    public virtual long bar(int n)
    {
        return 1 << n;
    }
}

That is, constant expression '1L' is converted to expression '1'.
Please fix! :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions