| |

VerySource

 Forgot password?
 Register
Search
Author: 阿迪雅

How to see pointer address in java

[Copy link]

2

Threads

16

Posts

11.00

Credits

Newbie

Rank: 1

Credits
11.00

 China

 Author| Post time: 2020-9-30 20:00:01
| Show all posts
So it can be used as an ID thing
------------------------
If it is really ID
            for (int i = 0; i <len; i++) {
                h = 31*h + val[off++];
            }
            hash = h;

But this. . This even has the qualifications called ID
Reply

Use magic Report

1

Threads

7

Posts

6.00

Credits

Newbie

Rank: 1

Credits
6.00

 China

Post time: 2020-9-30 20:15:01
| Show all posts
The ID of the object is not a reference, right?
Reply

Use magic Report

0

Threads

73

Posts

46.00

Credits

Newbie

Rank: 1

Credits
46.00

 China

Post time: 2020-9-30 22:15:01
| Show all posts
Ha ha, not a quote.
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-9-30 23:45:01
| Show all posts
Print the object directly, and print the "object address" in the form of a string for non-basic types
You can "visually" check if the two strings are the same
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-10-1 00:00:01
| Show all posts
Hey, discuss shellfish when discussing, you have to insult the other party!
Do you think insulting can solve the problem?
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list