I was looking for this right now and could not find an option in Oracle SQL Developer.
I know a service called SQL Fiddle , which can help in such situations when you need to test / analyze / test adhoc PL / SQL script. Using SQL Fiddle, you can do this:
Select Oracle 11g R2 (as available right now) in the drop-down list and enter the script in the left text area. Click the Build Schema button. If your script is valid, it will show you a Schema Ready message as follows:

source share