Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 377612

Summary: Detail formatter fails for SynchronizedMap
Product: [Eclipse Project] JDT Reporter: Markus Keller <markus.kell.r>
Component: DebugAssignee: JDT-Debug-Inbox <jdt-debug-inbox>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3    
Version: 3.8   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard: stalebug

Description Markus Keller CLA 2012-04-25 06:57:08 EDT
package xy;

import java.util.Collections;
import java.util.HashMap;
import java.util.Map;

public class Try {
    public static void main(String[] args) {
        HashMap<String, Integer> hashMap= new HashMap<String, Integer>();
        hashMap.put("bla", 11);
        hashMap.put("x", -3);

        Map<String, Integer> sync= Collections.synchronizedMap(hashMap);
        System.out.println(sync.toString());
    }
}

- breakpoint on last line
- set detail formatter for java.util.Map to:
return this.toString().replaceAll(", ", "\n,");

=> Says this for variable 'sync':
Detail formatter error:
		Evaluations must contain either an expression or a block of well-formed statements
Comment 1 Eclipse Genie CLA 2020-04-25 17:02:22 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.