Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 359456 - Ant Editor does not recognize extension points as valid targets
Summary: Ant Editor does not recognize extension points as valid targets
Status: RESOLVED DUPLICATE of bug 324625
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Ant (show other bugs)
Version: 3.7.1   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: 3.8 M2   Edit
Assignee: Platform-Ant-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-29 13:14 EDT by Wolfgang Gruber CLA
Modified: 2011-09-29 22:14 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Wolfgang Gruber CLA 2011-09-29 13:14:38 EDT
Overview:

Ant has an extension point system which allows to define extension-points and add targets to these extension-points. See https://ant.apache.org/manual/targets.html#extension-points for a detailed description.

The ant editor in Eclipse does not recognize the extension-point as valid target name if you add it to the dependencies of a target (depends="extensionPointName"). It marks the line as erroneous.

Steps to Reproduce: 

1. Create a build.xml

2. Add the following content:

<?xml version="1.0" encoding="UTF-8"?>
<project name="bug">
	
	<target name="run" depends="extPoint">
		<echo message="doing work" />
	</target>
	
	<extension-point name="extPoint" />
	
	<target name="useExtPoint_1" extensionOf="extPoint">
		<echo message="Ext Point called" />
	</target>
	
	<target name="useExtPoint_2" extensionOf="extPoint">
		<echo message="Ext Point called" />
	</target>
</project>

4. Open the build.xml with the ant editor

Actual Results:

The ant editor marks the line with "<target name="run" [..]" as erroneous. The error message is "Target extPoint does not exist in this project"

Expected Results:

The line should not be marked as erroneous because extPoint is an extension point and valid in the depends-attribute. If you run the run-target, it works as expected and calls the targets of the extension point.
Comment 1 Satyam Kandula CLA 2011-09-29 22:14:21 EDT
This has been fixed in 3.8M2.

*** This bug has been marked as a duplicate of bug 324625 ***