1
00:00:00,500 --> 00:00:02,709
Leo Dion (host): Welcome to
another episode of Empower Apps.

2
00:00:02,809 --> 00:00:04,709
I'm your host, Leo Dion.

3
00:00:04,809 --> 00:00:08,120
Today I'm joined by Saleem Abdulrasul.

4
00:00:08,349 --> 00:00:10,139
Saleem, thank you so much for coming on.

5
00:00:10,929 --> 00:00:11,829
Saleem Abdulrasool (guest):
Thank you for having me.

6
00:00:11,829 --> 00:00:12,549
It's a pleasure

7
00:00:13,049 --> 00:00:15,819
Leo Dion (host): I think this is
gonna be our first Windows-focused

8
00:00:15,819 --> 00:00:17,659
episode, so my, I'm excited.

9
00:00:18,159 --> 00:00:21,779
I'll let you introduce yourself
and how you got started into

10
00:00:21,779 --> 00:00:23,619
doing  Swift for Windows

11
00:00:24,119 --> 00:00:25,919
Saleem Abdulrasool (guest): Let me
take a pass at introducing myself then.

12
00:00:26,419 --> 00:00:27,710
So I'm Saleem Abdulrasool.

13
00:00:28,189 --> 00:00:30,149
Most people know me online as compnerd.

14
00:00:30,659 --> 00:00:33,489
I'm a systems engineer at The
Browser Company, but the thing

15
00:00:33,489 --> 00:00:37,399
I'm probably best known for is
that I brought Swift to Windows.

16
00:00:37,899 --> 00:00:40,920
I've worked on developer tooling
across both the LLVM and Swift

17
00:00:40,920 --> 00:00:44,990
projects, and on top of that, I
built  a set of my own things.

18
00:00:45,490 --> 00:00:48,539
The app framework SwiftWin32  the
Windows interop layers, and so on.

19
00:00:49,039 --> 00:00:51,139
Windows is really just
the last stop though.

20
00:00:51,750 --> 00:00:56,109
I was one of the original folks who got
Swift running on Android, and I did a few

21
00:00:56,109 --> 00:00:57,979
odd ones along the way, like PlayStation.

22
00:00:58,479 --> 00:01:03,869
I even laid some of the groundwork for
embedded Swift early on  before Apple

23
00:01:03,899 --> 00:01:05,959
took it up and ran much further with it.

24
00:01:06,729 --> 00:01:10,909
So my world is Swift with  Swift in
all the places people don't expect it.

25
00:01:11,409 --> 00:01:15,859
Leo Dion (host): Yeah, which I'm a big
fan of, so this is really exciting.

26
00:01:16,359 --> 00:01:22,159
I guess we'll maybe  let's
start by   why Swift on Windows?

27
00:01:22,209 --> 00:01:26,499
And you can either focus on personally
or within The Browser Company.

28
00:01:26,859 --> 00:01:28,109
What was your interest there?

29
00:01:28,609 --> 00:01:31,099
Saleem Abdulrasool (guest): I'd
say it's  conviction about the

30
00:01:31,109 --> 00:01:33,139
language plus a bit of stubbornness.

31
00:01:33,639 --> 00:01:37,639
I believed Swift-- in Swift early on,
right  as a language in its own right.

32
00:01:38,139 --> 00:01:40,999
And if you actually believe a
language is good, you want it

33
00:01:40,999 --> 00:01:42,169
to run where the people are.

34
00:01:42,669 --> 00:01:46,959
The vast majority of desktops out there
run Windows, so to me it was obvious.

35
00:01:47,629 --> 00:01:51,119
If Swift's going to be a serious
general purpose language, it

36
00:01:51,119 --> 00:01:52,519
needs to reach the Windows users.

37
00:01:53,019 --> 00:01:56,319
The other half was that everyone
said it wasn't really practical,

38
00:01:56,429 --> 00:01:59,859
and I had a pretty good idea it
was, so I wanted to prove it out

39
00:02:00,359 --> 00:02:01,679
Leo Dion (host): That's amazing.

40
00:02:02,179 --> 00:02:06,879
What about Swift were you like, "Yeah,
this needs to be…"  what about

41
00:02:06,879 --> 00:02:12,539
the language itself that you love
it  and why you were like, "Yeah, we

42
00:02:12,539 --> 00:02:17,979
need to  use Swift in Windows and not
just go to  C++ or C# or something"?

43
00:02:18,479 --> 00:02:18,539
Saleem Abdulrasool (guest): Yeah.

44
00:02:19,039 --> 00:02:25,469
The, with Swift, right, like what I saw
was  a, a language that kind of shed

45
00:02:25,479 --> 00:02:28,099
its  heritage in some senses, right?

46
00:02:28,099 --> 00:02:31,389
Like it, it didn't have the
baggage   that other languages had.

47
00:02:31,399 --> 00:02:36,859
So C++ kind of derived itself from
C, and with C-  Swift  it, it took

48
00:02:36,859 --> 00:02:39,909
some inspiration from a variety of
different languages, but it didn't

49
00:02:39,909 --> 00:02:41,359
really bring them forward, right?

50
00:02:41,359 --> 00:02:43,169
It's not like I'm just
going to evolve the syntax.

51
00:02:43,169 --> 00:02:46,879
It was just like take a clean break
and look at what the languages

52
00:02:46,889 --> 00:02:49,349
are and what they're trying to do.

53
00:02:49,379 --> 00:02:53,409
And so it came from that
foundation, like we now understand

54
00:02:53,409 --> 00:02:54,579
what we need from languages.

55
00:02:54,579 --> 00:02:58,049
Let's actually go back and think
about this and do something correctly.

56
00:02:58,049 --> 00:02:59,779
So we have a memory safe language.

57
00:03:00,209 --> 00:03:06,459
You have clean syntax, and   it really
went, I don't need to do everything.

58
00:03:06,959 --> 00:03:08,809
I can coexist in this world.

59
00:03:09,109 --> 00:03:16,459
And so you have this excellent interop
story that allows it to blend all the

60
00:03:16,469 --> 00:03:17,799
things that you already have, right?

61
00:03:17,799 --> 00:03:20,999
It's not  oh, let me go out
and rewrite everything at once.

62
00:03:21,019 --> 00:03:24,189
It's a, I can progressively
move to a better place.

63
00:03:24,689 --> 00:03:25,099
Leo Dion (host): Right.

64
00:03:25,549 --> 00:03:30,249
So as you were working on Swift for
Windows, was there any particular

65
00:03:30,479 --> 00:03:33,909
language feature that made that
experience easier for you at all?

66
00:03:34,409 --> 00:03:36,609
Saleem Abdulrasool (guest): The
experience of bringing it over or,

67
00:03:36,617 --> 00:03:36,987
Leo Dion (host): Yeah.

68
00:03:37,127 --> 00:03:37,837
Bringing it over.

69
00:03:37,837 --> 00:03:41,357
Was there something about like
async/await or certain language

70
00:03:41,357 --> 00:03:44,697
features that you were like, "Okay,
now this is gonna be way more viable"?

71
00:03:45,197 --> 00:03:48,197
Saleem Abdulrasool (guest): Not--   I
wouldn't say  that's really the case.

72
00:03:48,727 --> 00:03:53,797
I push back on the idea that  some of
the language features made it easier.

73
00:03:53,797 --> 00:03:56,737
If anything, the language
evolving is one of the things

74
00:03:56,737 --> 00:03:58,527
that made it   more difficult.

75
00:03:59,027 --> 00:04:01,707
A lot of the features land on
Apple's platforms first, right?

76
00:04:01,737 --> 00:04:04,167
And Windows comes into the picture.

77
00:04:04,637 --> 00:04:06,557
Concurrency actually is a good example.

78
00:04:07,257 --> 00:04:09,797
By the time we were bringing it
to Windows, the model already

79
00:04:09,807 --> 00:04:11,867
had baked and shipped, right?

80
00:04:11,867 --> 00:04:16,707
So  it's a fun problem  because
it's not just a library feature.

81
00:04:17,207 --> 00:04:22,597
The model shares  stacks in a stack
space, and to control stack growth,

82
00:04:22,597 --> 00:04:24,607
it relies on guaranteed tail calls.

83
00:04:25,517 --> 00:04:28,547
And  that's a calling
convention guarantee, right?

84
00:04:28,587 --> 00:04:31,787
And calling conventions are one of
the areas where Windows differs.

85
00:04:32,517 --> 00:04:33,207
So

86
00:04:33,405 --> 00:04:33,855
Leo Dion (host): Right

87
00:04:34,517 --> 00:04:34,807
Saleem Abdulrasool (guest): yeah.

88
00:04:35,257 --> 00:04:39,217
And then  another thing was async
function pointer representation, right?

89
00:04:39,467 --> 00:04:43,027
It didn't really work on Windows,
and that started a bug in someone's

90
00:04:43,027 --> 00:04:46,887
program, and the work was reducing
it down to a minimal test case,

91
00:04:46,947 --> 00:04:50,647
root causing why the representation
broke, and then eventually designing

92
00:04:50,647 --> 00:04:52,217
a workaround using pointer tagging.

93
00:04:52,227 --> 00:04:55,127
So   it's some low-level
piece of the puzzle, right?

94
00:04:55,127 --> 00:04:57,577
It's not just a simple
recompile and it works.

95
00:04:58,077 --> 00:05:00,797
Leo Dion (host): Can you like deep
dive more   into some of those

96
00:05:00,797 --> 00:05:06,637
challenges as far as like how Windows
does things differently from Linux

97
00:05:06,687 --> 00:05:09,597
or any of the Apple platforms?

98
00:05:10,097 --> 00:05:12,827
Saleem Abdulrasool (guest): I guess
there, there's plenty of differences.

99
00:05:13,647 --> 00:05:17,137
Are there areas that you're
potentially drawn to or

100
00:05:18,071 --> 00:05:18,361
Leo Dion (host): No.

101
00:05:18,391 --> 00:05:22,221
Just what do you think is the most obvious
thing or challenge that you had to face,

102
00:05:22,721 --> 00:05:25,291
Saleem Abdulrasool (guest): I don't think
that there's one obvious thing, right?

103
00:05:25,341 --> 00:05:30,041
one of the things is
that it's been all over.

104
00:05:30,581 --> 00:05:37,681
And I don't know if you  actually
read my or watched my talk  from the

105
00:05:37,681 --> 00:05:40,361
LLVM Developer Conference in  2019.

106
00:05:40,861 --> 00:05:46,081
It was  called Porting by a Thousand
Patches, and that's because it really has

107
00:05:46,081 --> 00:05:48,861
been just one thing after another, right?

108
00:05:49,361 --> 00:05:52,291
That, that's one of the things
that you learn is th- this

109
00:05:52,301 --> 00:05:53,721
port was never impossible.

110
00:05:54,371 --> 00:05:59,591
It just was accepting the fact
that every time you fix one thing,

111
00:05:59,591 --> 00:06:03,181
three more things pop up, and just
showing up to keep knocking them down

112
00:06:03,681 --> 00:06:06,781
Leo Dion (host): Is there just like a
different philosophy behind how Windows

113
00:06:06,811 --> 00:06:10,141
works as opposed to the other ones

114
00:06:10,641 --> 00:06:14,841
Saleem Abdulrasool (guest): if you squint,
I think that you realize that  all of

115
00:06:14,841 --> 00:06:16,661
these operating systems look similar.

116
00:06:17,161 --> 00:06:18,711
And that, that's one of
the interesting things.

117
00:06:18,711 --> 00:06:23,621
I'd actually argue that Windows at
this point feels more similar to me

118
00:06:23,621 --> 00:06:25,771
than--  to macOS than it does to Linux.

119
00:06:26,271 --> 00:06:26,621
Leo Dion (host): Okay.

120
00:06:26,631 --> 00:06:27,371
In what way?

121
00:06:27,871 --> 00:06:31,941
Saleem Abdulrasool (guest): Microsoft
really takes  API stability to heart.

122
00:06:32,441 --> 00:06:38,581
Microsoft has maintained API stability
for close to 30-some years now, right?

123
00:06:38,591 --> 00:06:44,441
Like applications written in
1995 will run just fine today

124
00:06:45,097 --> 00:06:45,437
Leo Dion (host): Mm-hmm.

125
00:06:46,257 --> 00:06:47,617
That makes total sense.

126
00:06:47,997 --> 00:06:50,837
it almost seems like they're going
in the other direction where like,

127
00:06:50,877 --> 00:06:55,697
"Come on guys, get off of Windows
10, move to Windows 11." If anything,

128
00:06:55,857 --> 00:06:59,767
they… It's a, it's become a
burden to them  if that makes sense

129
00:07:00,267 --> 00:07:04,577
Saleem Abdulrasool (guest): Yeah  it's
definitely a challenge to keep programs

130
00:07:04,577 --> 00:07:06,157
running for that length of time.

131
00:07:06,657 --> 00:07:10,697
I think that Microsoft has some great
engineers, and they've managed to do

132
00:07:10,717 --> 00:07:14,617
an exceptional job, and Apple has done
an amazing job at this as well, right?

133
00:07:14,677 --> 00:07:15,887
this is the reality.

134
00:07:15,887 --> 00:07:19,337
These companies are large and
have some excellent engineers that

135
00:07:19,337 --> 00:07:24,217
are able to perform some heroics
for  keeping software running well.

136
00:07:24,787 --> 00:07:28,407
But that's part of that
commitment to API stability.

137
00:07:28,907 --> 00:07:32,717
But at the same time, there's
also ideas of security, right?

138
00:07:33,077 --> 00:07:38,477
Both these platforms go to extents to
make sure that their users are safe.

139
00:07:38,977 --> 00:07:41,667
Both of them sort of
have mature ecosystems.

140
00:07:42,497 --> 00:07:48,167
Both of them   have multiple
distribution mechanisms, and so there's

141
00:07:48,177 --> 00:07:50,067
a lot of similarities between these.

142
00:07:50,567 --> 00:07:52,417
Linux is growing too, right?

143
00:07:52,687 --> 00:07:55,387
It's not  oh, it's completely different.

144
00:07:55,387 --> 00:07:58,477
It's just that   it's taken a different
route to get to the same place.

145
00:07:58,477 --> 00:08:04,697
And while API stability has never been
one of its   core  areas of focus for

146
00:08:04,697 --> 00:08:11,607
the user space, I think that  they've
been making  progress towards  shoring

147
00:08:11,617 --> 00:08:13,407
up the rest of the ecosystem, right?

148
00:08:13,607 --> 00:08:18,167
And the package managers on Linux
are always something that people

149
00:08:18,587 --> 00:08:20,597
sort of compare themselves to, right?

150
00:08:20,817 --> 00:08:22,447
That's where a lot of
these ideas came from.

151
00:08:22,447 --> 00:08:27,227
So the port system in BSD, package
managers on Linux  they're phenomenal.

152
00:08:27,247 --> 00:08:30,477
And so you have a lot of those
ideas bleeding over now to

153
00:08:30,477 --> 00:08:31,637
these other platforms too.

154
00:08:32,569 --> 00:08:32,999
Leo Dion (host): Yeah.

155
00:08:33,089 --> 00:08:36,529
Yeah, that's one thing I've noticed
when I was working with Windows.

156
00:08:37,029 --> 00:08:43,729
So let's talk maybe about like a
showcase of some great use cases

157
00:08:43,739 --> 00:08:46,099
for where this has happened.

158
00:08:46,129 --> 00:08:50,779
I put in my list command line tools,
for instance, work across the board.

159
00:08:51,279 --> 00:08:53,939
Is there any command line tools
in s- written in Swift that

160
00:08:53,939 --> 00:08:56,049
you can think of off the top of

161
00:08:56,071 --> 00:08:57,821
Saleem Abdulrasool (guest): there's
definitely an interesting one that

162
00:08:57,851 --> 00:09:00,551
everyone likes to use, the Swift compiler

163
00:09:01,051 --> 00:09:01,501
Leo Dion (host): Yeah.

164
00:09:01,571 --> 00:09:03,081
So yeah, talk about that

165
00:09:03,899 --> 00:09:04,179
Saleem Abdulrasool (guest): Yeah.

166
00:09:04,609 --> 00:09:07,569
The command line surface is
probably the most mature one.

167
00:09:08,069 --> 00:09:10,379
And the best proof is the
toolchain itself, right?

168
00:09:10,409 --> 00:09:12,299
Like the Swift toolchain uses Swift now.

169
00:09:12,799 --> 00:09:16,039
And when the thing that builds the
language is written in the language

170
00:09:16,199 --> 00:09:19,359
on the platform, that tells you
that the story is real, right?

171
00:09:19,859 --> 00:09:23,769
Building and running native command line
tools on Swift on Windows works today.

172
00:09:23,919 --> 00:09:26,449
The language and API support
is there, is complete.

173
00:09:27,369 --> 00:09:32,099
But there is one nuance though, and
it's a fun Windows is not Unix thing.

174
00:09:32,599 --> 00:09:34,839
The command line environment
is quite different.

175
00:09:35,679 --> 00:09:41,239
Windows historically doesn't have
the same  PTY/TTY concept  Unix

176
00:09:41,239 --> 00:09:45,769
does, and it traditionally didn't
render the console using ANSI escape

177
00:09:45,769 --> 00:09:47,659
sequences the way Unix terminals do.

178
00:09:48,039 --> 00:09:50,229
It used proper Windows APIs for that.

179
00:09:51,123 --> 00:09:51,473
Leo Dion (host): Okay

180
00:09:51,809 --> 00:09:53,679
Saleem Abdulrasool (guest): And
that changed with Windows Terminal.

181
00:09:53,699 --> 00:09:58,269
Microsoft added  the tooling and
the API support to host enough

182
00:09:58,269 --> 00:10:02,779
of the TTY concept and moved over
to ANSI escape-based rendering.

183
00:10:03,339 --> 00:10:07,069
So the language support is great, but
it's not quite apples to apples, no pun

184
00:10:07,069 --> 00:10:11,219
intended   because the console model
underneath is just a different world.

185
00:10:11,269 --> 00:10:15,019
Leo Dion (host): So in a previous life
I was a Microsoft developer, because if

186
00:10:15,019 --> 00:10:18,129
you wanna be a salaried employee in the
Midwest, you pretty much have to be.

187
00:10:18,629 --> 00:10:25,459
But when I was young  I got into .NET,
C#, and then just before I started

188
00:10:25,519 --> 00:10:30,759
kind of slowly moving into the Apple
space  PowerShell had become a thing.

189
00:10:31,259 --> 00:10:36,329
How does that… 'Cause I researched
before this writing my own Windows app

190
00:10:36,789 --> 00:10:40,749
and one of the things was like how like
I was confused by  okay, so there's

191
00:10:40,749 --> 00:10:45,279
like command line, there's PowerShell,
and then a lot… There's a few things

192
00:10:45,289 --> 00:10:48,939
out there where   I don't know what
it's called, but you can kind of do

193
00:10:48,939 --> 00:10:53,119
like Linux-y terminal stuff on Windows.

194
00:10:53,569 --> 00:10:56,889
Like   explain the differences
in that whole ecosystem, 'cause

195
00:10:56,889 --> 00:10:58,359
it was really confusing to me.

196
00:10:58,469 --> 00:10:58,589
Saleem Abdulrasool (guest): Sure.

197
00:10:59,089 --> 00:11:01,849
So just to make sure I'm
following, are you talking about

198
00:11:01,889 --> 00:11:03,379
Windows Subsystem for Linux?

199
00:11:03,879 --> 00:11:05,909
Leo Dion (host): I think that's
exactly what I'm talking about, yeah.

200
00:11:06,509 --> 00:11:10,459
Yeah, 'cause there's like the
old school basically DOS brought

201
00:11:10,459 --> 00:11:14,319
in, there's PowerShell, and then
there's the thing you just said

202
00:11:14,659 --> 00:11:15,089
Saleem Abdulrasool (guest): Yeah.

203
00:11:15,329 --> 00:11:20,879
No, you're right that  Microsoft's
environment is  sometimes scary for

204
00:11:20,879 --> 00:11:23,039
a new user because it's just so vast.

205
00:11:23,539 --> 00:11:28,889
I think that the first thing to
think about is the-- again, right?

206
00:11:29,019 --> 00:11:32,229
If you squint just right, all of
these platforms look the same.

207
00:11:32,709 --> 00:11:36,319
on Windows, right, you have this
shell, you have this window that you're

208
00:11:36,319 --> 00:11:39,939
interacting with, and  in a lot of
ways, this is what you see on macOS

209
00:11:39,939 --> 00:11:43,259
and Linux as well, where you have this
window that you're working on, you

210
00:11:43,269 --> 00:11:46,819
have a shell within it, and you're
able to launch commands and whatnot.

211
00:11:47,749 --> 00:11:53,149
Now Windows actually, the way that I think
about it, has It did not have a shell.

212
00:11:53,649 --> 00:11:53,969
All right?

213
00:11:53,969 --> 00:11:55,889
What it had was a batch interpreter.

214
00:11:55,889 --> 00:12:00,909
and this is meaningful when you actually
try to understand that ecosystem

215
00:12:00,909 --> 00:12:02,669
and why things are the way they are.

216
00:12:03,529 --> 00:12:07,269
The batch interpreter is meant to be
not an interactive tool that you're

217
00:12:07,529 --> 00:12:09,719
using to work with the computer with.

218
00:12:09,989 --> 00:12:15,319
It's meant to be just a host to
run a predetermined script, right?

219
00:12:15,719 --> 00:12:19,369
So that's what   the
DOS command prompt was.

220
00:12:19,369 --> 00:12:21,069
It was a batch interpreter, really.

221
00:12:21,569 --> 00:12:26,159
PowerShell was Microsoft's
first foray into this, an idea

222
00:12:26,169 --> 00:12:28,629
of a interactive shell almost.

223
00:12:29,009 --> 00:12:33,149
And  they came at it from a
completely different place than

224
00:12:33,149 --> 00:12:34,949
where the Unix environment came from.

225
00:12:35,449 --> 00:12:39,889
PowerShell was meant to be this,
th- this different environment

226
00:12:39,899 --> 00:12:44,529
where you actually     you were
performing operations against objects.

227
00:12:44,729 --> 00:12:48,819
So it's this very Smalltalk-ish
environment, right?

228
00:12:48,929 --> 00:12:52,799
You have all of the  all of these
things that you're working against, and

229
00:12:52,799 --> 00:12:56,719
you're piping them into one another,
and you're building up this pipeline

230
00:12:56,719 --> 00:12:58,469
of commands that you're g-  executing,

231
00:12:58,969 --> 00:12:59,999
Leo Dion (host): It almost like,

232
00:13:00,019 --> 00:13:00,709
Saleem Abdulrasool (guest): of objects

233
00:13:01,009 --> 00:13:03,809
Leo Dion (host): what I remember was
like, it was almost like they were

234
00:13:03,809 --> 00:13:06,939
trying to bring .NET into the shell.

235
00:13:07,439 --> 00:13:11,959
A lot of the same APIs were more
li- like whatever you can do in

236
00:13:11,959 --> 00:13:14,169
code you can do with PowerShell

237
00:13:14,669 --> 00:13:15,599
Saleem Abdulrasool (guest): Right.

238
00:13:16,099 --> 00:13:19,309
So that c that's a separate
aspect of PowerShell.

239
00:13:19,329 --> 00:13:24,829
So PowerShell has this idea of you have
objects and you have properties on these

240
00:13:24,829 --> 00:13:28,759
objects that you're interacting with, and
you're able to pipe them to each other

241
00:13:28,759 --> 00:13:30,249
and you're able to build a pipeline.

242
00:13:30,839 --> 00:13:34,859
And   fun little aside, the
original name  the code name for

243
00:13:35,089 --> 00:13:36,769
PowerShell used to be Monad, right?

244
00:13:36,779 --> 00:13:40,389
Like the idea is that it's a monadic
operation stream that you're building up.

245
00:13:40,889 --> 00:13:45,069
The, the aspect that you're referring
to is actually a feature that they've

246
00:13:45,399 --> 00:13:49,149
built out because PowerShell itself is
built on top of the .NET environment,

247
00:13:49,539 --> 00:13:55,789
and .NET environment has this really
cool concept of running over a VM, right?

248
00:13:55,799 --> 00:13:59,629
Like the v- the virtual machine
that it executes on is  the CLR.

249
00:14:00,129 --> 00:14:03,449
And so what it's able to do is it's
able to use a funct- a piece of

250
00:14:03,449 --> 00:14:05,139
functionality there, which is P/Invoke.

251
00:14:05,379 --> 00:14:09,289
It allows it to do a platform in-
invocation and bridge right into

252
00:14:09,289 --> 00:14:13,259
the .NET ecosystem and bring all
of that into the shell itself

253
00:14:13,917 --> 00:14:14,287
Leo Dion (host): Got it.

254
00:14:14,507 --> 00:14:14,827
Okay

255
00:14:15,327 --> 00:14:19,857
Saleem Abdulrasool (guest): So that's sort
of the  PowerShell environment  itself.

256
00:14:19,887 --> 00:14:22,917
And then y- since you're asking
about  the Windows subsystem for

257
00:14:22,917 --> 00:14:28,347
Linux  this is actually going into
another aspect of Windows  where

258
00:14:28,647 --> 00:14:33,357
Windows again is this… I- it's
this interesting environment, right?

259
00:14:33,357 --> 00:14:37,867
Like the NT k-  the kernel itself, the
NT kernel   is  very powerful and it's

260
00:14:37,877 --> 00:14:42,457
very flexible   just because of the way
it was designed and  the ideas behind it.

261
00:14:42,957 --> 00:14:49,707
One of the ideas that  the NT kernel had
was the idea of execution environments.

262
00:14:50,557 --> 00:14:54,827
So i- if you go back to the original
time that this was all being developed,

263
00:14:55,177 --> 00:14:57,587
Microsoft was working with  IBM, right?

264
00:14:57,587 --> 00:15:02,267
They  they had this partnership and
there was this other OS, OS/2, and

265
00:15:02,267 --> 00:15:07,547
the idea was to actually be able to
natively host executables from different

266
00:15:07,577 --> 00:15:09,897
OSs under the same environment.

267
00:15:09,907 --> 00:15:13,587
So you could take an OS/2 executable
and you could execute it on Windows.

268
00:15:13,797 --> 00:15:17,547
It would run under the NT under a
separate sus- subsystem, so it could

269
00:15:17,547 --> 00:15:21,837
actually provide you the necessary
infrastructure for the OS/2 environment.

270
00:15:22,337 --> 00:15:29,317
And so Microsoft actually did this
really clever thing of they built yet

271
00:15:29,317 --> 00:15:34,837
another subsystem, which was the  Windows
subsystem for Linux, and this allowed

272
00:15:34,837 --> 00:15:39,727
them to build  or to execute Linux
executables  against the NT kernel.

273
00:15:40,427 --> 00:15:47,177
What they found is that people didn't
necessarily want  that model per se.

274
00:15:47,417 --> 00:15:52,987
They wanted a much more richer Lin-  pure
complete Linux environment, and so they

275
00:15:53,247 --> 00:15:59,157
switched over from that to the Windows
subsystem for Linux 2, which actually

276
00:15:59,467 --> 00:16:04,497
is more of this full Linux environment
that's running   alongside of Windows.

277
00:16:04,527 --> 00:16:08,617
And so  that's where   you were
referring to of being able to just

278
00:16:08,617 --> 00:16:11,847
run that Linux environment, where
it is actually the Linux kernel

279
00:16:11,857 --> 00:16:14,187
that's running  on Windows as well.

280
00:16:14,487 --> 00:16:16,297
Leo Dion (host): That is
the same thing, essentially.

281
00:16:16,947 --> 00:16:18,447
Linux, Windows for Linux.

282
00:16:18,927 --> 00:16:19,637
Interesting.

283
00:16:20,167 --> 00:16:23,905
I didn't know that  that
goes back to OS/2   wow.

284
00:16:24,165 --> 00:16:28,465
Okay, 'cause OS/2 is  that was
IBM's like little experiment back

285
00:16:28,465 --> 00:16:30,565
in the '90s that did not work out.

286
00:16:31,065 --> 00:16:31,545
Okay.

287
00:16:32,085 --> 00:16:32,945
Super interesting.

288
00:16:32,945 --> 00:16:33,915
I did not know that.

289
00:16:34,415 --> 00:16:39,005
I… So one thing I was intrigued
by, I had this conversation with

290
00:16:39,005 --> 00:16:44,105
Giannis at   SwiftCraft, and we were
talking about how big of a deal it is

291
00:16:44,105 --> 00:16:46,395
to get server-side Swift on Windows.

292
00:16:46,775 --> 00:16:50,835
And I was like, " why would you care
to get a server-side Swift in Windows?"

293
00:16:51,335 --> 00:16:54,395
Most servers that I know
of are running Linux.

294
00:16:54,985 --> 00:16:59,585
And then we got into this whole thing
about how there's  and I knew, I kinda

295
00:16:59,585 --> 00:17:03,835
know this now, but in reflection,
I didn't realize at the time, was

296
00:17:03,835 --> 00:17:07,015
like, oh yeah, there's a lot of
companies that's have to run Windows

297
00:17:07,285 --> 00:17:08,925
and have to run Windows servers.

298
00:17:09,265 --> 00:17:14,545
And so getting Swift, server-side Swift
working on Windows is really important

299
00:17:15,055 --> 00:17:21,875
because it gives us an opportunity   to
basically write a server  for a, a ton

300
00:17:21,875 --> 00:17:24,135
of people who run Windows as servers.

301
00:17:24,635 --> 00:17:28,495
Now I, like I said, in a previous
life, I had done some .NET and

302
00:17:28,795 --> 00:17:30,615
worked with IIS and all that stuff.

303
00:17:30,865 --> 00:17:34,525
Kind of explain, first of
all   how getting a server work

304
00:17:34,525 --> 00:17:38,025
on Windows, the challenge of that,
and then why is it so important?

305
00:17:38,525 --> 00:17:38,695
Saleem Abdulrasool (guest): Yeah.

306
00:17:39,195 --> 00:17:41,975
To really tell you this one, you
have to go back to around the turn of

307
00:17:41,975 --> 00:17:44,415
the millennium  to the C10K problem.

308
00:17:44,915 --> 00:17:48,495
The challenge of handling 10,000
simultaneous connections on one server.

309
00:17:49,341 --> 00:17:49,871
Leo Dion (host): Yeah

310
00:17:50,855 --> 00:17:53,255
Saleem Abdulrasool (guest): Windows
actually was a serious server environment

311
00:17:53,285 --> 00:17:58,335
very early  and a lot of enterprise
flocked to it, and in part of it

312
00:17:58,335 --> 00:17:59,995
was because of its async I/O model,

313
00:18:00,495 --> 00:18:00,785
Leo Dion (host): Okay

314
00:18:00,857 --> 00:18:02,687
Saleem Abdulrasool (guest):
I/O completion ports or IOCP.

315
00:18:03,237 --> 00:18:05,447
And IOCP is genuinely interesting.

316
00:18:05,967 --> 00:18:12,217
It's a completion-based model where the OS
hands you back data once the I/O is done.

317
00:18:12,717 --> 00:18:15,667
That's quite different from the
traditional Unix readiness model

318
00:18:16,307 --> 00:18:20,137
where the OS just tells you a
socket is ready and you go read it.

319
00:18:20,637 --> 00:18:23,277
For a long time, that made
Windows kind of its own world.

320
00:18:23,767 --> 00:18:28,067
Interestingly  Linux actually has moved
towards the same  completion model

321
00:18:28,067 --> 00:18:32,307
recently with io_uring, so the two
are closer now than they've ever been.

322
00:18:32,807 --> 00:18:35,867
But the point is that Windows has
always been a capable server-ready

323
00:18:35,887 --> 00:18:39,087
platform, and there's real
interest in writing servers there.

324
00:18:39,337 --> 00:18:41,617
The catch really is the
tooling story in Swift.

325
00:18:42,117 --> 00:18:46,437
The center of gravity for server-side
Swift is NIO   the networking framework.

326
00:18:47,137 --> 00:18:50,997
And I actually got NIO working
on Windows back in April 2020.

327
00:18:51,497 --> 00:18:55,417
But we never really managed to get that
work integrated upstream into NIO itself.

328
00:18:55,637 --> 00:18:58,887
And  there was a second push, and
now there's a third push happening.

329
00:18:59,167 --> 00:19:02,727
And I'm genuinely hopeful
that  this latest one lands

330
00:19:02,767 --> 00:19:04,457
'cause the goal is simple, right?

331
00:19:04,477 --> 00:19:05,507
You-- And worth it.

332
00:19:05,507 --> 00:19:08,677
You should be able to write server
software on Windows easily in a, a

333
00:19:08,687 --> 00:19:12,897
reliable, safe, modern language and
take full advantage of the advanced

334
00:19:12,917 --> 00:19:14,827
networking Windows actually has.

335
00:19:15,327 --> 00:19:19,227
Leo Dion (host): Well, so we have it
fully working now, but it's just waiting

336
00:19:19,227 --> 00:19:21,297
on a merge,  is that the understanding?

337
00:19:21,797 --> 00:19:24,237
Saleem Abdulrasool (guest): So a lot
of the original work had bit rotted.

338
00:19:24,607 --> 00:19:28,857
There are multiple people
now   Johannes included  Jake

339
00:19:28,877 --> 00:19:31,187
also put up some  recent patches.

340
00:19:31,187 --> 00:19:34,857
there's a lot of people actually
pushing on it now, and hopefully this

341
00:19:34,857 --> 00:19:37,117
work will finally  see day of light.

342
00:19:37,617 --> 00:19:40,617
Leo Dion (host): And just for those
who don't know, can you explain

343
00:19:41,107 --> 00:19:45,717
why SwiftNIO is so important and
what it provides   on the server?

344
00:19:46,199 --> 00:19:51,219
Saleem Abdulrasool (guest): yeah  so
NIO basically is a engine, right?

345
00:19:51,219 --> 00:19:56,509
It is basically the reactor itself
which will  feed the data from the

346
00:19:56,509 --> 00:19:57,999
sockets into your application itself.

347
00:19:57,999 --> 00:20:02,269
So  it gives you the means
of quickly getting data from

348
00:20:02,269 --> 00:20:04,529
the socket  processing it.

349
00:20:05,029 --> 00:20:05,389
Excuse me.

350
00:20:05,889 --> 00:20:09,289
So getting that data, processing
it, and handing it off to the

351
00:20:09,289 --> 00:20:12,649
application so that the application
can form the application logic.

352
00:20:13,149 --> 00:20:17,339
And so when you have that, that
infrastructure, you can quickly stand

353
00:20:17,349 --> 00:20:21,439
up these applications and have them
scale   to what you normally expect

354
00:20:21,439 --> 00:20:24,789
these days from the machines which
have grown significantly from the

355
00:20:24,889 --> 00:20:26,289
turn of the millennium time, right?

356
00:20:26,789 --> 00:20:28,159
Leo Dion (host): Yeah,
that makes total sense.

357
00:20:28,659 --> 00:20:34,939
And then I guess the last piece
to talk about is the desktop app

358
00:20:35,439 --> 00:20:38,579
infrastructure, which you've worked
a lot on at The Browser Company.

359
00:20:39,079 --> 00:20:41,899
From my understanding,
there's  two ways of doing this.

360
00:20:42,399 --> 00:20:47,619
And then I chose the way to just
use the Windows SDK in Swift way.

361
00:20:47,999 --> 00:20:53,449
Explain kind of that journey and where
things stand for building Windows apps.

362
00:20:53,841 --> 00:20:55,641
Saleem Abdulrasool (guest):
Yeah  y-you're right.

363
00:20:56,491 --> 00:20:59,111
Desktop is where the majority
of Windows users are, so we

364
00:20:59,111 --> 00:21:00,631
really do need to focus there.

365
00:21:01,121 --> 00:21:03,771
And the state today is that
there's no single UI framework.

366
00:21:03,771 --> 00:21:04,911
It's bring your own UI.

367
00:21:05,411 --> 00:21:09,071
Why don't I walk you through my own path
because it kind of maps the whole space?

368
00:21:09,571 --> 00:21:13,091
I started with Swift Win32, which
gives you a native app framework

369
00:21:13,141 --> 00:21:15,861
built around the classic Win32 APIs.

370
00:21:16,231 --> 00:21:21,201
But I wanted some more of the modern
UI  components, so I started looking

371
00:21:21,201 --> 00:21:26,781
at WinRT and WinUI, and that pulled
me into building Swift COM  to talk

372
00:21:26,781 --> 00:21:30,601
to COM, and then Swift WinMD  to
read the metadata that describes

373
00:21:30,601 --> 00:21:32,471
the full Windows API surface.

374
00:21:32,971 --> 00:21:35,101
I also poked at DirectX along the way.

375
00:21:35,601 --> 00:21:39,681
And at The Browser Company, we're actually
using a fork of the WinMD work to generate

376
00:21:39,691 --> 00:21:42,351
bindings to WinUI, and we build with that.

377
00:21:42,851 --> 00:21:44,891
And here's the part
that I'm excited about.

378
00:21:45,391 --> 00:21:48,561
Swift on Windows has matured to
the point where we can now tackle

379
00:21:48,961 --> 00:21:53,271
something we'd always said that we
could do someday  proper COM interop

380
00:21:54,071 --> 00:21:56,261
and with the compiler helping.

381
00:21:56,761 --> 00:21:59,761
The idea is to bring Swift's
ARC  the automatic reference

382
00:21:59,761 --> 00:22:03,151
counting to COM because COM is
reference counted at its core.

383
00:22:04,109 --> 00:22:04,409
Leo Dion (host): Okay

384
00:22:05,061 --> 00:22:06,891
Saleem Abdulrasool (guest): Microsoft
actually tried something in this

385
00:22:06,891 --> 00:22:11,961
spirit years ago with C++/CX  where the
language extension managed to d-  the

386
00:22:11,981 --> 00:22:16,561
ref counting for you, though they later
decided that a library-based ap-  based

387
00:22:16,561 --> 00:22:18,831
approach was  a better fit for C++.

388
00:22:19,331 --> 00:22:23,441
Swift is interesting here because
it already has ARC built in, so

389
00:22:23,511 --> 00:22:24,941
it's a much more natural fit.

390
00:22:25,331 --> 00:22:28,971
And the model we're working towards
is a natural native Swift  that

391
00:22:29,021 --> 00:22:30,681
just happens to bridge over to COM.

392
00:22:31,381 --> 00:22:33,831
And in a lot of ways, that's the
same thing that Apple did with

393
00:22:33,841 --> 00:22:36,721
Swift, Objective-C, and Core
Foundation, toll-free bridging,

394
00:22:36,741 --> 00:22:40,701
first-class conveniences, the language
doing the bookkeeping for you.

395
00:22:41,501 --> 00:22:45,231
And   I've restarted  the
WinMD work to support this.

396
00:22:45,951 --> 00:22:50,031
All of this is in the open, so
honestly, that, that whole thing is

397
00:22:50,031 --> 00:22:53,611
its own  con-  conversation about
the approach and technology, so

398
00:22:53,611 --> 00:22:55,541
let's not go  too deep into that.

399
00:22:56,041 --> 00:22:59,131
Leo Dion (host): And we'll provide
links to these repos  in the show

400
00:22:59,131 --> 00:23:01,311
notes below so you can check that out.

401
00:23:01,811 --> 00:23:04,481
How would you recommend
somebody get started?

402
00:23:04,951 --> 00:23:11,831
Because I went with the Win SDK
route and had Claude basically

403
00:23:12,331 --> 00:23:14,161
doing what I wanted to do.

404
00:23:14,661 --> 00:23:15,871
What would you recommend?

405
00:23:16,371 --> 00:23:16,881
Saleem Abdulrasool (guest): Yeah.

406
00:23:17,381 --> 00:23:20,961
So the, the Windows SDK is definitely
the easiest way to get started.

407
00:23:21,461 --> 00:23:27,971
The, the reality is that the WinUI
environment, as enticing as it  is

408
00:23:27,981 --> 00:23:30,391
not  so developer-friendly yet.

409
00:23:30,891 --> 00:23:32,021
something that we are working on.

410
00:23:32,021 --> 00:23:37,161
The, and the idea is that the COM
interop  once that  is ready, will

411
00:23:37,181 --> 00:23:43,441
need  naturally open up  full access to
WinRT, which is what WinUI is based on.

412
00:23:43,941 --> 00:23:49,741
So you have COM allowing us to bridge
to WinRT, which opens up WinUI, and

413
00:23:49,741 --> 00:23:55,101
then we get the full fidelity WinUI APIs
without necessarily having to build up

414
00:23:55,111 --> 00:23:57,221
all the projections ourselves manually.

415
00:23:57,721 --> 00:24:04,331
So there, i-i-if you are  an intrepid
developer, you can of course  use the

416
00:24:04,341 --> 00:24:08,631
fork from The Browser Company that
has all this functionality there.

417
00:24:09,131 --> 00:24:13,611
We did an i-initial investigation
where we used the old WinMD approach

418
00:24:13,631 --> 00:24:16,521
and generated  the bindings manually.

419
00:24:16,531 --> 00:24:23,011
And there are  some places where there
are little hidden  trapdoors where you

420
00:24:23,011 --> 00:24:26,301
might find yourself stepping through
and it's like, "I did not expect that."

421
00:24:27,041 --> 00:24:31,511
And that, that's just the state of
the, the original projections, right?

422
00:24:31,971 --> 00:24:37,121
There was a lot of hand-rolled
dual models to do the bridging

423
00:24:37,131 --> 00:24:39,561
between Swift and C-  and COM.

424
00:24:39,701 --> 00:24:43,851
And the idea is with Swift  with
the COM interop in Swift, we should

425
00:24:43,861 --> 00:24:46,261
be able to bridge to that much more

426
00:24:46,761 --> 00:24:50,441
Leo Dion (host): I want to   take a
minute and explain some of these concepts.

427
00:24:50,871 --> 00:24:56,311
So  I remember building like
Windows apps using C# 15,

428
00:24:56,781 --> 00:24:56,791
Saleem Abdulrasool (guest): Mm-hmm.

429
00:24:56,931 --> 00:24:58,161
Leo Dion (host): 16 years ago.

430
00:24:58,661 --> 00:25:04,001
And then obviously there was
COM, M- MFC was one of 'em.

431
00:25:04,501 --> 00:25:07,401
And now you're talking about
WinRT, you're talking about WinUI.

432
00:25:07,691 --> 00:25:10,401
What are these and how do these
all work together within the

433
00:25:10,401 --> 00:25:11,811
Windows desktop environment?

434
00:25:12,571 --> 00:25:13,811
Saleem Abdulrasool (guest):
Yeah, absolutely.

435
00:25:14,651 --> 00:25:17,241
I think this is one of those
other places where you end up with

436
00:25:17,241 --> 00:25:18,941
this stroll through memory lane.

437
00:25:19,559 --> 00:25:20,399
Leo Dion (host): Yeah, go for it.

438
00:25:21,099 --> 00:25:24,299
I'll even put in some  I'll
put in  what do you call it?

439
00:25:25,069 --> 00:25:28,649
Flashback  music here on the podcast

440
00:25:29,149 --> 00:25:30,279
Saleem Abdulrasool (guest):
That sounds amazing.

441
00:25:30,779 --> 00:25:33,659
So the Win32 API is really old.

442
00:25:34,419 --> 00:25:37,849
This came out of Project Chicago

443
00:25:38,349 --> 00:25:41,109
Leo Dion (host): O- one of the
key indicators is  that it's

444
00:25:41,129 --> 00:25:43,049
old is that it's called Win32.

445
00:25:43,549 --> 00:25:46,569
That's, that to me was like a
big tell like, yeah, this is

446
00:25:46,569 --> 00:25:48,659
pretty old if it's 32-bit based.

447
00:25:48,659 --> 00:25:49,729
But anyway, go ahead

448
00:25:50,229 --> 00:25:50,449
Saleem Abdulrasool (guest): Yeah.

449
00:25:50,449 --> 00:25:54,929
So th-this all  I believe came
out of Project Chicago, although

450
00:25:54,929 --> 00:25:56,349
some of it might predate it.

451
00:25:57,169 --> 00:26:01,329
So Project Chicago would be known
to most people as Windows 95.

452
00:26:01,829 --> 00:26:07,579
That's where a lot of these original
APIs  really first showed up  in, in the

453
00:26:07,629 --> 00:26:16,039
way that we tend to use them today with
GDI and    the, the whole proper  Windows

454
00:26:16,049 --> 00:26:18,549
handles and everything for the UI toolkit

455
00:26:19,049 --> 00:26:19,279
Leo Dion (host): Yep.

456
00:26:19,419 --> 00:26:23,649
And that's the way  I went,
which was ugly  but it worked.

457
00:26:23,809 --> 00:26:24,429
So yeah

458
00:26:24,929 --> 00:26:27,039
Saleem Abdulrasool (guest): And Microsoft
actually did evolve that through

459
00:26:27,529 --> 00:26:29,619
Windows 98 and Windows ME as well.

460
00:26:30,119 --> 00:26:36,019
The-- There was a separate parallel
piece of work that was going on.

461
00:26:36,519 --> 00:26:40,369
So if you think back now around the
same time with Windows 95, right?

462
00:26:40,709 --> 00:26:42,849
Microsoft had just released Windows 95.

463
00:26:42,869 --> 00:26:46,679
It was huge, and  people
wanted to build applications.

464
00:26:47,029 --> 00:26:54,119
And one of the things that   really was
interesting at that time was there were

465
00:26:54,119 --> 00:26:58,659
these applications that were dedicated
and did  really well for certain things.

466
00:26:59,519 --> 00:27:06,509
And  one of these examples is Excel,
which is to this day considered  best

467
00:27:06,509 --> 00:27:08,019
in class for spreadsheeting, right?

468
00:27:08,849 --> 00:27:15,119
So the idea there was, well, we have
all of this library of code where

469
00:27:15,119 --> 00:27:20,639
we've really invested in building
these high-fidelity applications.

470
00:27:20,649 --> 00:27:22,599
It'd be wonderful if we could reuse them.

471
00:27:23,099 --> 00:27:28,219
And that led to the idea of object
linking and embedding, and the idea

472
00:27:28,219 --> 00:27:32,969
was that you could embed  Excel into
your application and have that level

473
00:27:32,969 --> 00:27:36,649
of  spreadsheet work within your
application without having to rebuild it.

474
00:27:37,399 --> 00:27:42,599
And to do that train of thought basically
kind of grew out into COM, which was the

475
00:27:42,599 --> 00:27:48,479
Common Object Model   where you had a
representation that you could work with

476
00:27:48,489 --> 00:27:52,469
in-process, out-of-process, however you
really wanted to work with it, right?

477
00:27:52,969 --> 00:27:58,839
And so it just allows you to sort of
go, "I have this interface definition.

478
00:27:58,879 --> 00:28:01,889
I do not know how it's implemented
or anything, but I know this is the

479
00:28:01,889 --> 00:28:07,319
interface that it provides, and I have
its identity." These identities are GUIDs.

480
00:28:07,819 --> 00:28:13,719
And so you basically go, "Hey,
system, here's the identity  and

481
00:28:13,719 --> 00:28:14,939
this is the interface that I want.

482
00:28:15,179 --> 00:28:19,799
Give me that." And it just hands you
back an opaque interface, and you just

483
00:28:20,039 --> 00:28:24,119
work through that, and suddenly you
have the implementation f-  without

484
00:28:24,129 --> 00:28:25,849
having to really rebuild it yourself.

485
00:28:26,349 --> 00:28:29,479
And so this is a very
powerful concept, right?

486
00:28:29,479 --> 00:28:32,839
That it allows for this decomposition
and for people to focus on the

487
00:28:32,849 --> 00:28:34,159
areas that they're really good at.

488
00:28:34,659 --> 00:28:38,789
Microsoft basically took that and built
out their entire ecosystem with this idea,

489
00:28:38,819 --> 00:28:44,689
and so you have COM pervasive throughout
the OS now Fast forward to   Windows

490
00:28:44,749 --> 00:28:50,689
8, and around that time, one thing
that was becoming really popular was

491
00:28:51,079 --> 00:28:54,189
more of the  compute on the go, right?

492
00:28:54,189 --> 00:28:58,649
So people had tablets, people had
phones, people had these thin and light

493
00:28:58,649 --> 00:29:03,289
laptops, and the idea was: How do we
actually evolve the ecosystem to sort

494
00:29:03,289 --> 00:29:07,389
of work with that where  we're thinking
about the modern environment, right?

495
00:29:07,699 --> 00:29:09,159
So you have applications.

496
00:29:09,649 --> 00:29:13,879
We don't really care about where the
file is stored or how it's stored.

497
00:29:13,879 --> 00:29:17,359
What we want is, this is my data,
this is the application I'm working

498
00:29:17,359 --> 00:29:19,829
with, I just wanna do my job, right?

499
00:29:20,299 --> 00:29:24,979
And so-- A- and this is the model that
you see with today's phones, right?

500
00:29:25,349 --> 00:29:27,649
You don't have the file system
necessarily exposed to you.

501
00:29:27,649 --> 00:29:30,789
You have these applications, you have
your data, and it just magically,

502
00:29:31,289 --> 00:29:32,809
fluidly moves between them.

503
00:29:33,777 --> 00:29:35,317
Leo Dion (host): Are we
getting into XAML yet?

504
00:29:35,817 --> 00:29:39,507
Saleem Abdulrasool (guest): Oh, sorry,
I skipped entirely over XAML, and I

505
00:29:39,517 --> 00:29:46,797
think that  it sounds, it, it-- The,
the chronology being a little out of

506
00:29:47,197 --> 00:29:50,817
order here actually helps understand
everything, how they fit together.

507
00:29:51,317 --> 00:29:55,977
The idea was that you have these
applications   that are isolated,

508
00:29:56,167 --> 00:29:58,917
and you don't want them to
leak data to each other, right?

509
00:29:58,917 --> 00:30:00,677
You want to be in control of your data.

510
00:30:00,677 --> 00:30:06,127
So that led to this idea of
the Windows Runtime application

511
00:30:06,387 --> 00:30:07,487
for applications, right?

512
00:30:07,487 --> 00:30:12,727
So Windows Runtime or WinRT was that
substr-  substrate that Microsoft built

513
00:30:12,727 --> 00:30:15,117
up for these ty-  new modern applications.

514
00:30:15,617 --> 00:30:21,987
And so you have this new environment
where you can build these, these modern

515
00:30:21,987 --> 00:30:27,717
applications   that, that sort of
abstract away the idea of file system,

516
00:30:27,747 --> 00:30:32,797
the environment, and all of these things
that people  that are working    with

517
00:30:32,797 --> 00:30:34,077
the command line are familiar with.

518
00:30:34,477 --> 00:30:35,717
All of that just goes away.

519
00:30:35,717 --> 00:30:37,917
You have applications and you
have your data, and that's

520
00:30:37,917 --> 00:30:38,867
all you need to think about.

521
00:30:39,367 --> 00:30:43,037
When they did this, because you
were building up these more modern

522
00:30:43,037 --> 00:30:46,577
applications, they wanted to change the
look and feel of these applications.

523
00:30:46,927 --> 00:30:52,947
And so they basically repurposed what
they'd built with   Windows, w-  around

524
00:30:52,947 --> 00:30:58,287
the Windows ME ti-  right after Windows
ME  or around Windows ME with XAML, right?

525
00:30:58,787 --> 00:31:04,007
XAML basically was this idea of
building out a declarative UI.

526
00:31:04,447 --> 00:31:05,427
Shocking, I know.

527
00:31:05,557 --> 00:31:07,527
No one w-  has ever thought of that idea.

528
00:31:08,305 --> 00:31:08,515
Leo Dion (host): Mm-hmm.

529
00:31:08,615 --> 00:31:09,035
Yeah.

530
00:31:09,505 --> 00:31:09,835
Yeah

531
00:31:10,047 --> 00:31:11,117
Saleem Abdulrasool (guest):
hey, it's computer science.

532
00:31:11,177 --> 00:31:14,137
We see the same problems
just  again and again, right?

533
00:31:14,999 --> 00:31:17,339
Leo Dion (host): It's like
storyboards and interface builder.

534
00:31:17,439 --> 00:31:19,179
That's what you're alluding to, right?

535
00:31:19,209 --> 00:31:19,509
Yeah

536
00:31:19,725 --> 00:31:20,195
Saleem Abdulrasool (guest): Yes.

537
00:31:20,695 --> 00:31:21,645
And SwiftUI.

538
00:31:22,441 --> 00:31:25,261
Leo Dion (host): No,
I  being facetious, but yes.

539
00:31:25,761 --> 00:31:26,381
Saleem Abdulrasool (guest): All of
these  yeah, the, the thing is though

540
00:31:27,181 --> 00:31:28,751
it is all the same concepts, right?

541
00:31:28,751 --> 00:31:29,711
Again, if you scroll,

542
00:31:30,531 --> 00:31:33,481
Leo Dion (host): Well  I think
HTML was a big inspiration,

543
00:31:33,791 --> 00:31:35,951
Saleem Abdulrasool (guest): HTML was
also a big inspiration, you're right.

544
00:31:36,469 --> 00:31:36,809
Leo Dion (host): Yeah

545
00:31:37,309 --> 00:31:39,699
Saleem Abdulrasool (guest): so
XAML basically allowed you to mark

546
00:31:39,699 --> 00:31:41,479
up the UI that you wanted, right?

547
00:31:41,479 --> 00:31:47,009
So they were able to be a bit
more flexible  about how that UI

548
00:31:47,039 --> 00:31:50,359
evolved, and so they were able
to reuse that to build out the UI

549
00:31:50,859 --> 00:31:55,199
That unfortunately never really   took
off in the way that they were hoping.

550
00:31:55,699 --> 00:32:00,899
And so basically  what they found
is that the people who were using

551
00:32:00,899 --> 00:32:04,579
the applications really clamored for
native applications on the desktop.

552
00:32:05,049 --> 00:32:10,639
And so they basically took the
WinRT   layer and evolved that, right?

553
00:32:10,929 --> 00:32:16,459
And from that you ended up with
WinUI, which is  the new UI layer

554
00:32:16,469 --> 00:32:18,169
for building Windows applications.

555
00:32:18,669 --> 00:32:23,249
And this basically is built on top of
WinRT, which is built on top of COM,

556
00:32:23,529 --> 00:32:29,709
and so you have now the new UI layer,
and this was shipped as part of the OS,

557
00:32:29,709 --> 00:32:33,719
which meant that, well, if you want to
update, that's kind of difficult, right?

558
00:32:34,349 --> 00:32:35,899
OSs don't ship every day.

559
00:32:36,379 --> 00:32:41,819
So Microsoft actually took that and
said, "Actually, we can put in the effort

560
00:32:41,879 --> 00:32:44,189
and break this out of the OS," right?

561
00:32:44,229 --> 00:32:49,719
And so that's where we come up with
WinUI 3, where it's been  separated from

562
00:32:49,719 --> 00:32:54,969
the OS itself and allows you to ship a
version with your application, and it's

563
00:32:54,969 --> 00:33:00,459
being adopted by both Microsoft and
elsewhere in building new UI applications.

564
00:33:00,959 --> 00:33:03,529
Leo Dion (host): So
yeah, that was awesome.

565
00:33:03,569 --> 00:33:07,569
I appreciate that very much  because
that explains a lot that I've

566
00:33:07,569 --> 00:33:08,989
missed in the last 15 years.

567
00:33:09,489 --> 00:33:11,229
What I don't know where to start.

568
00:33:11,239 --> 00:33:12,379
I have two questions.

569
00:33:12,879 --> 00:33:20,829
One is, how do you recommend your
typical iPhone developer with a

570
00:33:20,829 --> 00:33:25,949
Mac, how should they get started
building, like trying out Swift for

571
00:33:25,949 --> 00:33:27,579
Windows and building a desktop app?

572
00:33:27,999 --> 00:33:29,109
What's the best route there?

573
00:33:29,609 --> 00:33:29,629
Saleem Abdulrasool (guest): Yeah.

574
00:33:29,649 --> 00:33:29,719
So th-there's two aspects to it.

575
00:33:29,729 --> 00:33:31,669
Let me start with the first one, which
is how do you really get started?

576
00:33:31,679 --> 00:33:33,759
'Cause I feel like that's
what you're trying to ask.

577
00:33:34,327 --> 00:33:34,587
Leo Dion (host): Mm-hmm.

578
00:33:35,087 --> 00:33:37,437
Saleem Abdulrasool (guest): So
Windows is a much older and more

579
00:33:37,437 --> 00:33:42,107
complicated landscape than most people
expect, and one of the things that

580
00:33:42,107 --> 00:33:44,857
I actually like about it is that
it lets you work the way you want.

581
00:33:45,517 --> 00:33:48,557
So the answer kind of
depends a bit on who you are.

582
00:33:49,057 --> 00:33:53,157
For most people, you just wanna
download the installer and run it, and

583
00:33:53,637 --> 00:33:57,147
that's had a huge overhaul  recently
to make the experience really smooth.

584
00:33:57,647 --> 00:33:58,117
That gives

585
00:33:58,193 --> 00:34:00,673
Leo Dion (host): do you even get,
how do you even get Windows though?

586
00:34:01,033 --> 00:34:02,033
You've skipped a part.

587
00:34:02,463 --> 00:34:02,713
Saleem Abdulrasool (guest): Yeah.

588
00:34:03,213 --> 00:34:09,263
I assume that  y- you have Windows  on
Ma-- If you're running just on macOS

589
00:34:09,273 --> 00:34:13,333
hardware, I think that Parallels right
now is the only way because of the

590
00:34:13,415 --> 00:34:14,665
Leo Dion (host): Yeah,
that's what I ended up doing

591
00:34:15,165 --> 00:34:15,515
Saleem Abdulrasool (guest): Excuse me.

592
00:34:16,095 --> 00:34:21,405
And then  if you have Intel
hardware  you should be able to

593
00:34:21,405 --> 00:34:25,275
just  get Windows  from  Microsoft.

594
00:34:25,775 --> 00:34:28,445
It r- it runs on a wide
variety of hardware, right?

595
00:34:28,445 --> 00:34:30,545
Th-  and that's one of
the important things that

596
00:34:30,871 --> 00:34:34,421
Leo Dion (host): I found the opposite
is true, that my, all my Windows

597
00:34:34,421 --> 00:34:38,301
machines, so I don't have a lot,
are too old to run Windows 11.

598
00:34:38,841 --> 00:34:44,551
So I ended up going with Parallels  for a
lot of reasons, one of which is just the

599
00:34:44,561 --> 00:34:49,181
ease, the ability to be able to develop on
the same machine that I'm using day to day

600
00:34:49,681 --> 00:34:53,431
Saleem Abdulrasool (guest): I would
say that  it feels that way  but

601
00:34:53,431 --> 00:34:56,561
when you actually truly look at
the requirements, it's interesting.

602
00:34:57,061 --> 00:35:02,221
Most of these machines that are
required to    like those minimum

603
00:35:02,221 --> 00:35:05,891
requirements for Windows, usually
they're asking for a machine from

604
00:35:05,891 --> 00:35:08,981
around 2012, 2013 at the earliest.

605
00:35:09,765 --> 00:35:10,065
Leo Dion (host): Okay

606
00:35:10,881 --> 00:35:14,481
Saleem Abdulrasool (guest): So
that's about 13 years ago now.

607
00:35:14,883 --> 00:35:15,953
Leo Dion (host): Yeah, that's true.

608
00:35:16,833 --> 00:35:21,953
But also  it could be faster 'cause
Apple Silicon's so solid, it could

609
00:35:21,973 --> 00:35:27,123
honestly be faster to develop in a
VM than it would be to develop on a

610
00:35:27,133 --> 00:35:29,473
desktop that's 13 years old or two.

611
00:35:29,633 --> 00:35:31,623
So yeah, something to consider

612
00:35:32,295 --> 00:35:32,755
Saleem Abdulrasool (guest): Yes.

613
00:35:33,255 --> 00:35:39,165
For what it's worth  I actually did spend
some time  with a machine specifically

614
00:35:39,175 --> 00:35:44,395
for testing that  actual developer
workflow where I don't actually develop

615
00:35:44,395 --> 00:35:45,935
Swift, but I develop with Swift.

616
00:35:46,675 --> 00:35:53,525
And what I did was I purchased a
Project Tiny Mini Micro, I believe

617
00:35:53,525 --> 00:35:55,525
is what they're called  machine.

618
00:35:56,025 --> 00:36:01,495
Like a $100 machine off of eBay from
like 2012, and I was just doing f- all

619
00:36:01,495 --> 00:36:03,525
of the development right on that, right?

620
00:36:04,075 --> 00:36:04,535
And

621
00:36:05,035 --> 00:36:05,865
Leo Dion (host): That's
really good to know

622
00:36:06,497 --> 00:36:08,297
Saleem Abdulrasool (guest):
it worked  pretty great.

623
00:36:08,297 --> 00:36:12,187
Like my biggest complaint was I
need to switch machines so that

624
00:36:12,727 --> 00:36:16,987
I can do d- my actual compiler
development to my actual  application

625
00:36:16,987 --> 00:36:19,527
development, and the application
development was just so much easier.

626
00:36:19,787 --> 00:36:20,197
Leo Dion (host): Yeah.

627
00:36:20,707 --> 00:36:24,707
I have, I usually  whenever I
need a Windows machine or a cheap

628
00:36:24,737 --> 00:36:30,147
computer, I've gotten like those, I
think they're HP EliteDesk machines.

629
00:36:30,307 --> 00:36:31,777
Yeah, those are super cheap too.

630
00:36:32,165 --> 00:36:33,375
Saleem Abdulrasool (guest):
Yeah, that, that's exactly what

631
00:36:33,447 --> 00:36:35,877
Leo Dion (host): hopefully
they're still super cheap.

632
00:36:36,237 --> 00:36:39,127
Well, we'll see in a, in
our current environment.

633
00:36:39,497 --> 00:36:42,817
But  the, the other, like I don't
know if you're gonna mention this,

634
00:36:42,817 --> 00:36:45,357
but  yeah   I set up PowerShell.

635
00:36:45,397 --> 00:36:49,607
I installed the latest version
of PowerShell, and I set up a

636
00:36:49,607 --> 00:36:52,017
SSH server so I can SSH into it.

637
00:36:52,517 --> 00:36:54,587
It just like there are a lot of pieces.

638
00:36:54,617 --> 00:36:58,147
Oh, you… So  part of the process,
and let me know if I'm stepping on

639
00:36:58,147 --> 00:37:01,937
your toes on this, but was like you
have to install the Visual Studio

640
00:37:01,957 --> 00:37:09,557
Community edition, and I believe it
was e- either 2012, is it 2022 or 2026?

641
00:37:09,557 --> 00:37:10,367
What would you recommend?

642
00:37:10,867 --> 00:37:13,647
Saleem Abdulrasool (guest): So
2022 is definitely supported.

643
00:37:14,147 --> 00:37:17,627
We've been actively working
on  the 2026 support.

644
00:37:18,127 --> 00:37:22,087
I've been using a combination
of the two, and I know that

645
00:37:22,145 --> 00:37:22,785
Leo Dion (host): ended up doing.

646
00:37:23,187 --> 00:37:23,527
Saleem Abdulrasool (guest): Sorry?

647
00:37:24,255 --> 00:37:26,245
Leo Dion (host): That's what I
ended up doing, was installing both

648
00:37:26,947 --> 00:37:27,117
Saleem Abdulrasool (guest): Yeah.

649
00:37:27,367 --> 00:37:33,157
And then  for ARM64 support, I
do recommend  Visual Studio 2026.

650
00:37:33,903 --> 00:37:34,173
Leo Dion (host): Okay.

651
00:37:34,697 --> 00:37:38,937
Saleem Abdulrasool (guest): But
yeah    I think  that's a good segue

652
00:37:38,957 --> 00:37:43,527
back to what I was saying where   you
just download the installer and run it.

653
00:37:44,027 --> 00:37:46,917
And that gives you everything
that you need with the one

654
00:37:46,917 --> 00:37:48,817
caveat that you already covered.

655
00:37:49,317 --> 00:37:52,597
We can't actually redistribute
Microsoft's SDK, and so you

656
00:37:52,597 --> 00:37:54,017
need to install Visual Studio.

657
00:37:54,157 --> 00:37:55,497
And any version is fine.

658
00:37:55,517 --> 00:37:59,247
Community is free, but  Professional,
Enterprise, it doesn't really matter.

659
00:37:59,707 --> 00:38:04,057
And you're installing it specifically
for the Windows SDK and the C library.

660
00:38:04,473 --> 00:38:04,773
Leo Dion (host): Right.

661
00:38:05,343 --> 00:38:08,293
Saleem Abdulrasool (guest): If you
want the build tools  there are enough.

662
00:38:09,203 --> 00:38:12,033
All we really need are just the
headers and the import libraries.

663
00:38:12,811 --> 00:38:12,961
Leo Dion (host): Right.

664
00:38:13,181 --> 00:38:13,441
Yeah

665
00:38:13,773 --> 00:38:16,153
Saleem Abdulrasool (guest):
And  there's a fun aside here.

666
00:38:16,493 --> 00:38:19,773
The whole idea of an import library,
the compact stub describing what

667
00:38:19,773 --> 00:38:24,593
a library exports, Windows has
had that since the early '90s  the

668
00:38:24,593 --> 00:38:29,883
NT era, and Apple introduced the
equivalent  the TBD files in 2015.

669
00:38:30,753 --> 00:38:34,073
So Microsoft was way ahead on
that one by a couple of decades.

670
00:38:34,573 --> 00:38:36,413
Leo Dion (host): We
covered how to get started.

671
00:38:36,913 --> 00:38:40,283
I  and maybe you have
experience with this.

672
00:38:40,333 --> 00:38:45,793
So in, in our current Apple world, there's
a lot of talk about how Mac apps don't

673
00:38:45,793 --> 00:38:48,153
look like Mac apps, et cetera, et cetera.

674
00:38:48,623 --> 00:38:54,083
People just develop Electron or people…
Like  what is the environment in

675
00:38:54,103 --> 00:38:56,393
Windows for developing Windows apps?

676
00:38:56,643 --> 00:39:00,843
Are people like  just  yeah, slap
together…  I'm sure there's a lot of

677
00:39:00,843 --> 00:39:05,743
slap together Electron apps  but  is
there guidance as far as like this

678
00:39:05,743 --> 00:39:09,193
is how you should make a Windows app,
this is how it should look, et cetera?

679
00:39:10,067 --> 00:39:10,387
Saleem Abdulrasool (guest): Yeah.

680
00:39:10,887 --> 00:39:15,417
Yes  there  there is guidance
on what is recommended.

681
00:39:15,827 --> 00:39:17,917
Microsoft does recommend WinUI 3.

682
00:39:18,437 --> 00:39:23,627
And  we are actively working on  we
being The Browser Company are

683
00:39:23,627 --> 00:39:25,337
actively working on improving that.

684
00:39:25,437 --> 00:39:29,347
And  we are  collaborating with
Apple on some of this as well.

685
00:39:29,847 --> 00:39:33,697
Hopefully that-- this, this is just going
to improve  over the next year or so.

686
00:39:34,197 --> 00:39:38,507
But  there is already  some
amount of support there in terms

687
00:39:38,507 --> 00:39:40,197
of examples of how to do that.

688
00:39:40,237 --> 00:39:44,657
There are in fact community members
who've  posted YouTube videos on how

689
00:39:44,657 --> 00:39:49,627
to  build with the  WinUI bindings that
we've generated at The Browser Company.

690
00:39:50,127 --> 00:39:51,137
Leo Dion (host): We'll put links to that

691
00:39:51,637 --> 00:39:56,087
Saleem Abdulrasool (guest): And   to your
other question   of how your application

692
00:39:56,087 --> 00:39:58,097
should use--   t- and you should look.

693
00:39:58,597 --> 00:40:03,097
Microsoft has   equivalences
to Apple's  HIG as well.

694
00:40:03,127 --> 00:40:07,737
So Microsoft has Human Interface
Guidelines, and you are generally

695
00:40:07,737 --> 00:40:11,687
recommended to follow those  for
a couple of reasons, right?

696
00:40:12,547 --> 00:40:18,527
You want to  fit into that environment
naturally, but it also makes your

697
00:40:18,527 --> 00:40:20,567
application feel at home that way, right?

698
00:40:21,477 --> 00:40:21,767
So

699
00:40:21,869 --> 00:40:22,229
Leo Dion (host): Mm-hmm.

700
00:40:23,209 --> 00:40:30,239
What   and then my, so the way I did it
was Windows SDK directly, and then my

701
00:40:30,239 --> 00:40:34,799
understanding for like the WinUI method,
which I assume is the alternative you're

702
00:40:34,799 --> 00:40:39,339
talking about, is you have to do some
compilery stuff to get that working.

703
00:40:40,299 --> 00:40:41,719
How much of a challenge is that?

704
00:40:42,309 --> 00:40:43,979
Or is that what you're talking
about when you say we should

705
00:40:43,979 --> 00:40:45,439
check out those YouTube videos?

706
00:40:45,929 --> 00:40:46,379
Saleem Abdulrasool (guest): Yeah.

707
00:40:46,569 --> 00:40:49,509
So that is not actually compilery work.

708
00:40:50,439 --> 00:40:55,679
The  the problem there is that the
bindings themselves require some

709
00:40:55,679 --> 00:41:02,959
amount of setup, and  that has
not been made as fluid as  just

710
00:41:03,159 --> 00:41:05,999
importing a package dependency yet.

711
00:41:06,763 --> 00:41:07,073
Leo Dion (host): Okay

712
00:41:07,299 --> 00:41:11,429
Saleem Abdulrasool (guest): And the hope
is that once we have COM interop, it will

713
00:41:11,429 --> 00:41:16,059
become, excuse me  a much simpler process
where you can just add in a package

714
00:41:16,059 --> 00:41:18,619
dependency and get the WinUI bindings.

715
00:41:19,459 --> 00:41:23,399
For the time being, you need to
set up an additional package and

716
00:41:23,399 --> 00:41:26,709
build that, and then pass that
along to your application build so

717
00:41:26,709 --> 00:41:27,869
that you're able to integrate that.

718
00:41:27,949 --> 00:41:29,039
That's, the complexity.

719
00:41:29,943 --> 00:41:30,343
Leo Dion (host): Got it.

720
00:41:30,693 --> 00:41:31,053
Okay.

721
00:41:31,863 --> 00:41:32,633
Very cool.

722
00:41:33,133 --> 00:41:36,173
I have another question
about window interop.

723
00:41:36,673 --> 00:41:41,873
Is there an ability to… So
there's a interop with C++, right?

724
00:41:41,883 --> 00:41:47,883
So you could do Windows SDK stuff  in
C++ and then bring that in as a Swift

725
00:41:48,103 --> 00:41:49,983
package or product or something, right?

726
00:41:50,723 --> 00:41:52,533
Is that, am I saying that correct?

727
00:41:53,217 --> 00:41:53,477
Saleem Abdulrasool (guest): Yeah.

728
00:41:53,997 --> 00:42:00,537
You can definitely have  a library that's
written in C and C++ and then be able to

729
00:42:00,847 --> 00:42:02,447
i-integrate that into your application.

730
00:42:02,447 --> 00:42:06,447
And in fact, that is what all
of this relies upon, right?

731
00:42:06,447 --> 00:42:08,537
is one of the fundamental
aspects of Swift itself.

732
00:42:08,537 --> 00:42:14,137
So that when you  Win32 API-based UI
application that you're describing

733
00:42:14,487 --> 00:42:16,237
actually relied on that C interop.

734
00:42:16,887 --> 00:42:19,207
So all of that should be
functioning just well.

735
00:42:19,267 --> 00:42:23,347
Leo Dion (host): Do most people do C++
or do most people do C#  in the micro?

736
00:42:23,357 --> 00:42:24,997
I would assume C# still, right?

737
00:42:25,027 --> 00:42:26,187
Or am I wrong?

738
00:42:26,687 --> 00:42:29,207
Saleem Abdulrasool (guest): I think
that you find that it goes back

739
00:42:29,207 --> 00:42:31,657
to Windows is pretty broad, right?

740
00:42:31,657 --> 00:42:34,817
You'll find people who are
writing in C# and you'll find

741
00:42:34,817 --> 00:42:35,967
people who are writing in C++.

742
00:42:36,407 --> 00:42:42,327
So   I don't know the actual counts, so
I can't really speculate, but there's

743
00:42:42,327 --> 00:42:45,237
definitely both sides of   development.

744
00:42:46,061 --> 00:42:47,761
Leo Dion (host): Is there  a C#?

745
00:42:48,261 --> 00:42:50,911
Well, I see some stuff about
XAML still, which is hilarious.

746
00:42:51,271 --> 00:42:56,891
But  is there any interop with  XAML
or C# in any way if you wanted to go

747
00:42:56,891 --> 00:42:59,251
that route than having to write C++?

748
00:42:59,751 --> 00:43:04,761
Saleem Abdulrasool (guest): so that on
its own is pretty complicated because

749
00:43:05,671 --> 00:43:07,711
there's so many different approaches.

750
00:43:08,571 --> 00:43:12,211
Microsoft actually has this
really interesting  technology

751
00:43:12,211 --> 00:43:18,041
they've built where you can
host XAML content within WinUI.

752
00:43:18,361 --> 00:43:21,331
So you have  what they call XAML Islands.

753
00:43:21,831 --> 00:43:25,111
And so you're able to have XAML
within your WinUI application

754
00:43:25,611 --> 00:43:27,021
that does not require C#.

755
00:43:27,571 --> 00:43:29,051
That does  you can do it with C++.

756
00:43:29,551 --> 00:43:32,801
And in fact, we've al-  at The
Browser Company have experimented

757
00:43:32,821 --> 00:43:34,811
with that with  Swift as well.

758
00:43:35,661 --> 00:43:42,141
And  I don't think we have anything where
it's something where we can just go and

759
00:43:42,141 --> 00:43:46,631
point you to a repository, go, "Here's
how you do it." But it is something

760
00:43:46,631 --> 00:43:51,181
that, you know  I think that will become
much easier to work with as the COM

761
00:43:51,311 --> 00:43:56,701
interop improves, because  that opens
up a much more convenient way to work

762
00:43:56,701 --> 00:43:59,721
with the WinRT APIs and therefore WinUI.

763
00:43:59,731 --> 00:44:04,451
And as you have the f- full fidelity WinUI
come over, you should be able to use the

764
00:44:05,111 --> 00:44:07,181
XAML Islands as well much more easily.

765
00:44:07,681 --> 00:44:11,181
Leo Dion (host): Has there been any
work done to bring  I don't wanna

766
00:44:11,181 --> 00:44:15,191
call it SwiftUI, but you know what
I mean, to be able to build UIs

767
00:44:15,241 --> 00:44:21,271
using SwiftUI-ish  into Windows?

768
00:44:21,771 --> 00:44:26,931
Saleem Abdulrasool (guest): So there--
the work of building out a framework for

769
00:44:27,221 --> 00:44:32,091
declarative UI is quite large, right?

770
00:44:32,381 --> 00:44:33,551
Leo Dion (host): I would imagine, yes.

771
00:44:33,661 --> 00:44:34,061
Yes.

772
00:44:34,561 --> 00:44:38,481
Saleem Abdulrasool (guest): I don't
know of any one complete solution.

773
00:44:38,981 --> 00:44:44,021
I think that especially if
you're looking for a fully native

774
00:44:44,021 --> 00:44:48,591
experience, I don't know of anyone
that has that fully built out yet.

775
00:44:49,091 --> 00:44:51,201
In some ways XAML itself is declarative.

776
00:44:51,701 --> 00:44:57,611
So  I think the question is really: what
is it that you're looking for, right?

777
00:44:57,651 --> 00:45:02,571
Are you looking for a, "I just drop
in my SwiftUI code and it works"?

778
00:45:02,751 --> 00:45:05,961
I don't know  if there's
a equivalent for that.

779
00:45:06,321 --> 00:45:09,961
If you're looking for, "How do I build
applic-  UI applications?" I think the

780
00:45:09,961 --> 00:45:15,311
answer is   we have multiple ways of
building out a UI on Windows right now.

781
00:45:15,721 --> 00:45:20,221
Some of them are more declarative
than others, and I think that  over

782
00:45:20,221 --> 00:45:25,691
time we should actually find  all of
these are going to start converging

783
00:45:26,051 --> 00:45:31,631
as   COM really becomes full fidelity
on    full fidelity within Swift.

784
00:45:32,475 --> 00:45:33,685
Leo Dion (host): Yep, I agree.

785
00:45:34,185 --> 00:45:39,945
Before we end, what are the future plans
for Windows  Swift on Windows, besides

786
00:45:39,945 --> 00:45:42,385
getting that PR merged for server side?

787
00:45:42,885 --> 00:45:46,185
Saleem Abdulrasool (guest): I think the
near-term future is really about  turning

788
00:45:46,185 --> 00:45:48,125
current limitations into strengths.

789
00:45:48,625 --> 00:45:49,835
I mentioned it a few times.

790
00:45:50,165 --> 00:45:54,075
The one that I'm most directly driving
is the COM Interop work   bringing

791
00:45:54,085 --> 00:45:57,765
Swift's ARC model to  COM, and that's
the big unlock because so much of

792
00:45:57,775 --> 00:46:01,435
Windows is built around COM, and not
just the UI, but the whole platform.

793
00:46:01,935 --> 00:46:02,075
Leo Dion (host): Yeah

794
00:46:02,557 --> 00:46:04,507
Saleem Abdulrasool (guest): Getting that
right means that Swift can integrate

795
00:46:04,517 --> 00:46:06,327
with Windows in a much more natural way.

796
00:46:06,827 --> 00:46:11,167
Debugging is the other big arc.  Getting
code view and PDBs fully in place

797
00:46:11,177 --> 00:46:14,337
so that the whole Windows tooling
ecosystem just works with Swift.

798
00:46:15,267 --> 00:46:18,197
And that's something I'm steering
through colleagues at The Browser Company

799
00:46:18,197 --> 00:46:21,737
and others at Apple rather than doing
it myself, which is a good sign for

800
00:46:21,737 --> 00:46:23,657
the  for where the project is, right?

801
00:46:24,117 --> 00:46:24,247
Leo Dion (host): Mm-hmm.

802
00:46:24,917 --> 00:46:28,327
Saleem Abdulrasool (guest): and  more
broadly, it's closing the last  few

803
00:46:28,347 --> 00:46:32,697
parity gaps  so that it works
on Windows is just assumed  the

804
00:46:32,697 --> 00:46:34,177
way it is on any other platform.

805
00:46:34,947 --> 00:46:35,237
Leo Dion (host): Yep.

806
00:46:35,737 --> 00:46:36,427
Very cool.

807
00:46:37,237 --> 00:46:39,747
Thank you so much for
coming on today, Saleem.

808
00:46:40,637 --> 00:46:41,407
I really appreciate it.

809
00:46:41,407 --> 00:46:42,537
It's good to finally meet you.

810
00:46:42,567 --> 00:46:45,217
I've heard so many good things
about you and your genius.

811
00:46:45,717 --> 00:46:47,637
Where can people find you online?

812
00:46:48,617 --> 00:46:48,927
Saleem Abdulrasool (guest): Yeah.

813
00:46:49,427 --> 00:46:51,877
First  again, thank you
for really having me.

814
00:46:52,287 --> 00:46:57,577
It was  wonderful to  chat with you
about all of these  old Windows details

815
00:46:57,577 --> 00:46:59,337
that  people often forget about.

816
00:46:59,837 --> 00:47:03,717
As to finding me  the easiest
is to just look for compnerd.

817
00:47:03,747 --> 00:47:05,267
That's me pretty much everywhere.

818
00:47:05,417 --> 00:47:10,447
I'm compnerd on GitHub, Mastodon,
X   and if Swift on Windows is what

819
00:47:10,447 --> 00:47:15,297
caught you here, the best place to
actually plug in is  the Swift forums.

820
00:47:15,337 --> 00:47:18,537
There's the Windows category and the
Windows work group is right there.

821
00:47:19,127 --> 00:47:21,717
Come say hi, tell us what you're
building or where you're stuck

822
00:47:22,217 --> 00:47:22,257
Leo Dion (host): Awesome.

823
00:47:22,617 --> 00:47:23,677
Thank you so much.

824
00:47:24,117 --> 00:47:27,097
If people aren't subscribed to the
newsletter, we just recently talked

825
00:47:27,107 --> 00:47:32,117
about some stuff with AI and how I've
been using AI in agentic development.

826
00:47:32,727 --> 00:47:38,697
We'll have another newsletter out
soon to talk about  the release of

827
00:47:38,707 --> 00:47:42,327
AtLeast, so  definitely take some
time enjoying that TestFlight.

828
00:47:42,467 --> 00:47:44,027
I'll have the link in the show notes.

829
00:47:45,017 --> 00:47:49,787
And then thank you for Patreons
like Steve Lipton for helping out.

830
00:47:50,417 --> 00:47:55,397
We post these episodes right away
on Patreon, so you can check out  if

831
00:47:55,397 --> 00:47:58,657
you wanna get early access, that's a
great way to do it, or sneak preview

832
00:47:58,657 --> 00:48:00,417
to future blogs and newsletters.

833
00:48:00,887 --> 00:48:01,637
Let me know.

834
00:48:02,137 --> 00:48:03,227
My company is BrightDigit.

835
00:48:03,317 --> 00:48:07,497
Check out brightdigit.com if you're
looking for help with anything, and we

836
00:48:07,497 --> 00:48:12,807
also have some availability for half an
hour consultation sessions, so I'll put

837
00:48:12,807 --> 00:48:14,617
a link to that in the show notes as well.

838
00:48:15,337 --> 00:48:19,367
I'm on Twitter @leogdion,
Mastodon @ leogdion@c.im  or you

839
00:48:19,367 --> 00:48:21,417
can reach me on LinkedIn at Leo G.

840
00:48:21,417 --> 00:48:26,727
Dion, or excuse me, Leo Dion, which
is my name 'cause f-  that is my

841
00:48:26,727 --> 00:48:28,487
handle, but you know what I mean.

842
00:48:28,617 --> 00:48:30,627
Anyways  I'll shut up.

843
00:48:31,077 --> 00:48:33,867
Thank you for joining, and I'll look
forward to talking to you later.

844
00:48:33,887 --> 00:48:34,527
Bye everybody.