nette / php-generator

🐘 Generates neat PHP code for you. Supports new PHP 8.3 features.
https://doc.nette.org/php-generator
Other
2.11k stars 138 forks source link

Allow real value of private nullable #166

Closed wimwinterberg closed 1 month ago

wimwinterberg commented 1 month ago

Since the latest version 4.1.6 there is indeed a BC with isNullable. Is it possible to add way to also retrieve the real nullable value?

Now when I want a property to have a default value of null I use 'new Literal('null')'. So there is a difference between having value null and new Literal('null')

Thank you!

dg commented 1 month ago

You are probably looking for the setInitialized() and isInitialized() methods.