db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Knut Anders Hatlen (JIRA)" <j...@apache.org>
Subject [jira] Updated: (DERBY-4412) Make getNegation() abstract in BinaryComparisonOperatorNode and UnaryComparisonOperatorNode
Date Mon, 19 Oct 2009 15:12:59 GMT

     [ https://issues.apache.org/jira/browse/DERBY-4412?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Knut Anders Hatlen updated DERBY-4412:
--------------------------------------

    Issue & fix info: [Patch Available]

All the regression tests passed.

> Make getNegation() abstract in BinaryComparisonOperatorNode and UnaryComparisonOperatorNode
> -------------------------------------------------------------------------------------------
>
>                 Key: DERBY-4412
>                 URL: https://issues.apache.org/jira/browse/DERBY-4412
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>    Affects Versions: 10.6.0.0
>            Reporter: Knut Anders Hatlen
>            Assignee: Knut Anders Hatlen
>            Priority: Trivial
>         Attachments: abstract.diff
>
>
> Both BinaryComparisonOperatorNode and UnaryComparisonOperatorNode have a method called
getNegation() with the following code:
> 		/* Keep the compiler happy - this method should never be called.
> 		 * We should always be calling the method in a sub-class.
> 		 */
> 		if (SanityManager.DEBUG)
> 		SanityManager.ASSERT(false,
> 					"expected to call getNegation() for subclass " +
> 					getClass().toString());
> 		return this;
> Instead of relying on asserts to detect missing method overrides at run-time, we should
make the methods abstract so that such errors are detected by the compiler.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message