Skip to content

Conversation

@maximkrouk
Copy link
Contributor

Since the swift-syntax dependency was updated and the PR fixes build errors, it would be nice to release 0.2.0 when it gets merged.

  • Updated and locked (to avoid unexpected build errors) swift-syntax version
  • Fixed deprecation warnings
  • Fixed compilation errors
  • Fixed tests
  • Couldn't fix AddAsync/AddCompletionHandler macros, they are called multiple times and produce diagnostic errors, but since it's a showcase I guess it shouldn't be a blocker for fixing compilation errors

- Updated and locked swift-syntax version
- Fixed deprecation warnings
- Fixed compilation errors
- Fixed tests
-----
Couldn't fix AddAsync/AddCompletionHandler macros, they are called multiple times and produce diagnostic errors
@stackotter
Copy link
Owner

Hey Maxim, thanks for the PR! I'll have a look at your changes and then merge if all good, but I've got a deadline today followed by an all-weekend event, so I likely won't get around to fixing the example macros (which I'd like to do before releasing v0.2.0).

For some reason I thought I'd already locked the swift-syntax version which would've avoided those build errors and warnings from appearing 😅 thanks for picking up on that and updating the dependency while you were at it, that'll also save me some time when updating to the stable release of swift-syntax whenever that happens.

Copy link
Owner

@stackotter stackotter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me 👍 there are a few things I'll change, but to get this merged today I'll do that when I update the broken macros.

@stackotter stackotter merged commit 9b2670c into stackotter:main Aug 25, 2023
@stackotter
Copy link
Owner

I'm actually quite pleasantly surprised about the changes that they've made to swift-syntax since I last used it. The newer API changes make it feel more swifty and consistent.

@maximkrouk
Copy link
Contributor Author

maximkrouk commented Aug 25, 2023

Yeah, the new API feels fancier 😅

Btw I was thinking about updates, it feels kinda important to keep up with the latest swift-syntax version, so it's probably worth making releases with the locked version, but then revert main branch Package.swift file to the default one, so you can get stability for release versions and still notice if something changed when you or someone else who forked the repo opens the package 🤔

@stackotter
Copy link
Owner

Btw I was thinking about updates, it feels kinda important to keep up with the latest swift-syntax version, so it's probably worth making releases with the locked version, but then revert main branch Package.swift file to the default one, so you can get stability for release versions and still notice if something changed when you or someone else who forked the repo opens the package 🤔

Hmm yeah that could be a good idea.

I finally got around to fixing up the tests so I've added the v0.2.0 tag now.

@maximkrouk
Copy link
Contributor Author

Random fun fact:
I was implementing @AssociatedObject macro for https://github.com/capturecontext/swift-foundation-extensions and I somehow I managed to break the compiler, so now it builds on CI, but I can't compile macros locally 🤡

Hopefully xcode reinstall will help 😅

@stackotter
Copy link
Owner

Lol rip, that's always so annoying when that happens

@maximkrouk
Copy link
Contributor Author

Well, after hours of searching for workarounds I managed to fix the issue, I simply forgot to declare a compiler plugin type 😅, but the error was not helpful at all 💀

@stackotter
Copy link
Owner

Haha that’s still weird that it didn’t happen in CI 🤔 macro compilation errors could definitely do with some improvement lol

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants