Property getter is unnecessarily unwrapped

Description

SnapCal project, IcsDocImportPanel.m.

Complete zip to reproduce the issue: https://drive.google.com/a/swiftify.com/file/d/1e5N8hV1D5UgZQWmFv-6hYbpRsCRWtkR4/view?usp=drivesdk

Produces the following:

`_fileURL` should not be unwrapped using `!` operator.

Environment

None

Activity

Show:
Alex Petuschak
October 7, 2019, 2:51 PM
Edited

Please take a look.

1) When converting IcsDocImportPanel.h+m files locally, there is no ! operator after return _fileURL (as expected).

2) Also, no !operator if I use the web-based File & Project Converter.

3) When I convert these files using the Finder extension or Advanced Project Converter, I get !after return fileURL.

Do you have any clues, why?

I guess this could be related to `InitStringsAndCollectionsWithDefaultValues` option, or other options' default values.

 

If you can’t easily figure out yourself, please share an Offline version with `InitStringsAndCollectionsWithDefaultValues` option added at HockeyApp.

Ivan Kh
January 29, 2020, 11:36 AM
Edited

Now it works perfectly well with default options and various combinations of "Initialize properties without initializers with default values of their type“ and "Initialize variables of String and collection types with empty literals by default“.

 

Version with this option is already in release (5.1.3)

Alex Petuschak
January 29, 2020, 11:44 AM

Please test this and close this out.

Assignee

Ivan Kh

Reporter

Alex Petuschak

Labels

None

Git Branch Name

None

GitHub Issue

None

Components

Fix versions

Priority

High
Configure