I might be able to make that work but it I think it would be pretty slow.
The algorithm loops through every tile on the edge of the player's field of vision (in this case the edges of the map) and shoots rays at all of those tiles. In the ray casting algorithm, all the tiles that the ray traverses are added to an array. When all the rays have been cast, I loop through the array and light all the tiles in it.
Therefore, when I am lighting a tile I don't implicitly know the distance from the tile and the player, and would need to do additional calculations per tile to figure that out which would slow down the lighting.