Friday, 16 February 2018

Afflicted

Afflicted has come as a real, enjoyable, surprise. I'd hardly read the review, so I just knew about the "found footage" style. As the story unveils I was getting shocked and amazed, this is one of the most interesting and original approaches to the Vampire genre in a really long while. Derek is one young guy on vacation in Europe for his once in a lifetime (and probably last) trip, that has been turned into a vampire and has no idea of it until the symptons become evident. His reactions and those of his best friend sharing the trip with him, their attempts to try to survive on non human blood, and the despair when finding that only fresh human blood makes the trick....

The story is distressing and frenetic, the locations are nice (Italian coastal villages and Paris!) and the "camera in hand" technique contributes a lot to the anguish that one breaths through the film. By the way, I don't know why this film is considered a "found footage" film, the footage is not found later on, but transmitted in real time to social networks... "found footage" and "self-recorded, camera in hand" are not the same to me.

I've always had a soft spot for vampire stories, in particular those where they are presented as elegant, aristocratic, decadent creatures. (We Are the Night, Underworld...) Audrey, the female vampire that turned Derek, is pretty interesting. I would have loved that she had been more present in the film giving us a better glimpse of her life, but her short appearance at the end is probably the best moment of the film. She decided to turn Derek into a vampire as a gift when she realised that he had a serious health condition threatening to end his life at any moment. The genious moment is when she tries to calm him saying "yes, you have to kill to live, but you can choose who you kill". That's an amazing idea. Normally vampires are either evil ones feeding on any easy victim, or good ones that manage to survive on blood intended for transfusions or some sort of synthetic one. Here we are given the perfect option, leverage that need to kill to eliminate those humans that do not deserve to be alive. Buff, I could immediately think of me as a vampire in Paris (or Toulouse, Marseille, Brussels...) spending the nights bleeding to death as many Salafists as I could find. Buff, in a few years radical Islam would no longer be a threat to our Civilization :-D

Thursday, 15 February 2018

L'Insulte

I pretty much enjoyed watching The Insult in the cinema last week. Being a Lebanese film, from a "political" perspective I would prefer it to have been shot in French as original language rather than Arab, but I was lucky that it was the contrary, cause that way it was screened in Arab with French subtitles. With my French (lack of) level, reading the subtitles is much easier than trying to understand spoken French...

Long in short the film is about how a small dispute between a Lebanese Christian and a Palestinian refugee degenerates into a serious problem that ends up turning into a state affair. During this course, it succeeds in showing us the chaos in which Lebanon has lived (and continues to live) for so long. If you think that the conflict in Lebanon is just a matter of Christians vs Muslims, you're pretty wrong, cause there's much more to it: Christians, all the different Muslim sects (Sunnis and Druze, Shia and Alewite), Leftists and particularly important, Palestinians.

When the film starts, the Christian is the bad guay, and the Palestinian the good guy (what unusual...) but as the film evolves and the past is brought to the present, things get much more complex and quite less dichotomic. The deep disdain that the Christian character feels for the Palestinians stems from the fact that he and his family are also refugees in their own country. At the beginning of the Lebanese war alleged Palestinian forces looted and massacred the Christian village where he lived. Everybody knows about the Palestinian drama, but very few people know about the Christian drama, and this is salt over open wounds. As the lawyer says during the trial "no people should have the monopoly of suffering".

The film also reflects how hard is to this day the life of Palestinian refugees in Lebanon (this documentary shows it quite well) but it could give the impression that it's just Christians who are against them. I think this is something beyond religious lines (bear in mind also that some Palestinians are Christians or even non religious), and is much more a Lebanese against "invaders" issue. Bearing in mind that the Presence of Palestinian forces (after Black September) in Lebanese soil was the last (but pretty important) drop that led to the Lebanese civil war, one could understand (but not justify) a certain "animosity" towards Palestinians and a desire of putting them out of the country...

I'm aware of few films about the Lebanese war, basically, the magnificent Incendies and the also rather good Waltz with Bashir, but it seems I can't find any recent documentary about the war itself (not about its consequences in nowadays Lebanon).

Wednesday, 7 February 2018

Destructuring/Deconstructing

Destructured assignment (simplify how to return multiple values from a function and assign them to the corresponding variables) is a feature that I had really missed in both C# and Javascript, and it has been added almost at the same time, with a different name and with different behaviour. I'll write a small summary here.

In C# the feature is called Deconstruction and you can use it out of the box returning the new ValueTuple type from your methods. ValueTuple has builtin support for deconstruction. For other types, in order to allow deconstruction the class will have to provide Deconstruct method/s. In both cases, there's a single syntax for the assignment "()". So the thing is like:

static (string name, string city, int age) GetData()
{
 return ("Didier", "Toulouse", 45);
}

var (name, city, age) = GetData();
//as the returned tuple has names I can switch the order
(city, name, age) = GetData();

// Compilation Error: Cannot deconstruct a tuple of '3' elements into '2' variables
// (name, age) = GetData();

//so we have to use a discard
(name, _, age) = GetData();

//we can use different names
var (n, c, a) = GetData();

As you can see in the example if you want to assign less variables than the elements in the returned tuple you can use "_" (called discards). Discards make much sense when the variable names you use and those in the returned tuple do not match, or when the returned tuples is not using names, but in the example above, I don't see the reason for getting that Compilation Error and needing the discards, but well, I guess I'm missing something.

In Javascript the feature is called destructuring and we have 2 different syntaxes, "{}" for object destructuring and "[]" for array destructuring. Some basic example:

function getAddress(){
 return {name: "Marseille", population: 1600000};
}

let {name, population} = getAddress();

//-------------------------

function getCities(){
 return ["Paris", "Toulouse", "Marseille"];
}

let [capital, aero, mediterranean] = getCities();

I think there's not much to say about Object destructuring, but for Array destructuring the main thing to bear in mind is that it can be used for any iterable object, not just for arrays (so probably it would be more clear to call it "destructuring with array syntax"). This means that if we want to implement destructuring in one custom object, same as in C# we use Deconstruct methods, in javascript we'll use the iterable protocol. Let's see an example of how the same object is destructured differently with the object and array syntaxes.

let obj = {
 name: "Francois",
 city: "Marseille"
};

obj[Symbol.iterator] = function* () {
 yield "item1";
 yield "item2";
 yield "item3";
};

//object destructuring, can not be customised 
let {name, city} = obj;
console.log("name: " + name + " city: " + city); 

console.log("----------------");

let [a, b] = obj;
console.log("a: " + a + " b: " + b); //a: item1 b: item2


//we can use "discards" ( ,)if we want access to only certain elements (with "holes" in between)
[a, , b] = obj;
console.log("a: " + a + " b: " + b); //a: item1 b: item3

As shown above, discards in javascript use the " ," syntax rather than "_". One interesting feature present in javascript and missing in C# (as far as I know)is destructuring into function parameters.


function printAddress({street, number, city}) {
 console.log(street + ", " + number + " (" + city + ")" );
}

let address = {
 street: "Republique", 
 number: 45,
 city: "Paris"
};

printAddress(address);

Sunday, 4 February 2018

Structs in C#

I've never been particularly interested in using structs rather than classes in C#. I guess it comes from the reasoning "JavaScript, Python, Groovy... do not have them, so why should I care?". They are available mainly (or only) for performance reasons that probably in most cases should not hit us, so why should we care too much?

The fact that the new Tuples introduced in C# 7 (ValueTuple) that make so nice to work with multiple return values are structs rather than classes has slightly woken up my interest in them. I remember that one important performance feature is that structs lack the Object header that all reference types (instances of a class) have. This header is 8 bytes or 16 bytes depending on whether you are in a 32 bits or 64 bits system. If you are working with many instances of that class or struct, this can make a huge difference.. Another thing that had in mind is that assignment and modifications can be a bit tricky. I've been reading about it, and doing some minor tests, so I'll write a short summary. This entry in MSDN already gives us most of what we need

A struct is a value type. When a struct is created, the variable to which the struct is assigned holds the struct's actual data. When the struct is assigned to a new variable, it is copied. The new variable and the original variable therefore contain two separate copies of the same data. Changes made to one copy do not affect the other copy.

Value type variables directly contain their values, which means that the memory is allocated inline in whatever context the variable is declared. There is no separate heap allocation or garbage collection overhead for value-type variables.

Heap vs Stack. When you declare a variable of struct type, the struct will be created directly in the stack. var myStruct = new MyStruct();
However, when a class has a struct field or property, the struct is stored in the Heap. The difference here with normal classes is that the field will get the struct inlined right there, rather than being a reference to another memory location.

Given that structs are either directly located in the stack or inlined, assignments are based on copying. We are doing copies of the struct when we assign a local struct variable to another, or we assign it to a struct field or property or we pass it as parameter. Let's see some examples:

    struct Address
    {
        public Address(string city, string street)
        {
            this.City = city;
            this.Street = street;
        }

        public string City;
        public string Street;

        public override string ToString()
        {
            return this.City + ", " + this.Street;
        }
    }

    class Person
    {
        public string Name {get;set;}
        public Address Location {get;set;}

        public Person(string name, Address location)
        {
            this.Name = Name;
            this.Location = location;
        }

        public override string ToString()
        {
            return this.Name + " - " + this.Location.ToString();
        }
    }

 
    //main
            var address1 = new Address("Marseille", "Port Vieux");
            //a copy of address1 is done and assigned to address2
            var address2 = address1;

            address1.Street = "Rue de la Republique";

            Console.WriteLine(address1.ToString()); //Rue de la Republique
            Console.WriteLine(address2.ToString()); //Port Vieux

            Console.WriteLine("----------------");
            
            //when we pass the struct as parameters its also a copy what gets passed
            var p1 = new Person("Francois", address1);

            Console.WriteLine(p1.ToString());
            //Republique

            address1.Street = "Rue du Temps";

            Console.WriteLine(p1.ToString());
            //Republique

            //with this assignment we are doing another copy
            p1.Location = address1;
            Console.WriteLine(p1.ToString());

            address1.Street = "Rue de la Liberte";
            Console.WriteLine(p1.ToString());
            //Temps

There's and important difference between modifying a struct through a field or a property. If my class has a struct property and I modify one of its fields, that struct itself is modified inline, I mean, given:

struct Address
    {
        public Address(string city, string street)
        {
            this.City = city;
            this.Street = street;
        }

        public string City;
        public string Street;

        public override string ToString()
        {
            return this.City + ", " + this.Street;
        }
    }

   class Container
    {
  public Address AddressProp {get;set;}
        public Address AddressField;
        
        public override string ToString()
        {
            return "Prop: " + this.AddressProp.ToString() + " - Field: " + this.AddressField.ToString();
        }
    }

We can do this instance.structField.field = value;

            var container = new Container();
            container.AddressField = new Address("Lyon", "Rue Victor Hugo");

            Console.WriteLine(container.ToString());
            //here I'm modifying the struct contents, the inlined values
            container.AddressField.Street = "Rue du Rhone";
            Console.WriteLine(container.ToString()); //Rhone

However, if it is a property, we'll get a compilation error instance.structProperty.field = value;

  container.AddressProp = new Address("Paris", "Boulevard Voltaire");
  //this line does not compile!!!
  container.AddressProp.Street = "Rue de Belleville";
 //Error: Cannot modify the return value of 'Container.AddressProp' because it is not a variable

Getting such compilation error makes sense. When accessing the property it's returning a copy that I'm not assigning, so the ensuing assignment is useless and the compiler just prevents it.

On the other side, both for properties and fields if I assign them to a variable I'll get a copy of the original struct that I can modify with no issue.

Wednesday, 31 January 2018

Die Turkey Die

The Kurdish people in Northern Syria (Rojava) have been an example of Humanism, Integrity and Struggle for all these last years. When I saw them in several interviews saying that their fight against ISIS was not just a fight for their people, but a fight for all of Humanity I could feel shivers down my spine. Used as we are to see how societies in the Middle East have descended into the Middle Ages led by Islam... see these people aiming to create a socialist society with equal rights for men and women and all ethnicities has been something beyond inspirational.

I was pretty aware of how difficult their path would be. Fighting the Islamist scum funded by petrodollars and Turkey, resisting the Turkish dirty war (arming and allowing the Islamist scum to cross the border, launching random attacks against Kurd revolutionaries under the pretext of being associated to the PKK...) But these Kurdish heros had managed to do the impossible, defeat ISIS, form a solid alliance with other non fundametalist ethnicities of the region, and liberate much more territory (both from ISIS and Assad) than anyone would have expected. Furthermore, they seemed to have gained international recognition as the most fierce and effective fighters against ISIS. I was not expecting to see in the next years Rojava turned into an official Kurdish state with full international recognition, but I could expect to see an Autonomous Region working as a sort of de-facto state. Once entered into a sort of peace (whatever instable this word is in that part of the world), one could expect thousands of Anarchists, Communists and Socialists (real ones, not IslamoLeft crap) moving there to help with the construction of this egalitarian society.

But all this was too much for the Turkish IslamoFascist beasts. As you know Erdogan has launched an all out war against the Rojava Kurds, the "olive branch operation" sending his troops and collaborating (even more openly) with remaining yihadist groups. One could expect that the international community that so willing was to use the Kurds to die on the ground fighting ISIS would show some sort of loyalty for their previous comrades, but it's not been at all like that, and we've seen one of the most ominous acts of treason in recent history. About the Putin Fascist openly collaborating with Erdogan, I think there's little to say. I wonder what the European far-right, that tends to see in Putin a sort of hero, a "defender of Christianity and moral "... thinks about this fucking traitor allying with the Islamist Turkish "empire". One could only wish to see the yihadists that are fleeing Syria and Irak join the Chechen Islamists and committing as many and as horrible attacks on Russian soil as posible...

I HATE Turkey for multiple reasons. For its present, a society that is more and more islamised and more and more nationalistic, that denies (and punishes those that don't) the Armenian and Greek genocides, that denies the existence of the Kurdish people... and for its past: the biggest enemy of Europe, that tried to conquer us multiple times and that unfortunately partially succeeded (the Balkans, Constantinople...) A society that massively votes for Erdogan and that adheres to the idea that when they emigrate, they and their sons and grandsons... will continue to be Turkish, rather than German, French or whatever country that has had the disgrace of seeing them set foot on their soil...

For sure the oppression of the Turkish people has made my hate for Turkey skyrocket... For the Kurds, lauching attacks on Turkish soil is a very problematic decision. If some civilian died Erdogan would have just what he desires so much, one more pretext to call them terrorists... so it should be the European progressist people who should attack (non violently I guess...) Turkish interests in our countries. Way beyond economical boykot, embassies, Turkish companies (Turkish Airlines agencies for example), Turkish cultural centres... should be targeted. Massive demonstrations burning Turkish flags, Turkish football teams being forced out of the stadiums when playing here... I can think of many ways to try to make them aware of how much we hate them and how much one day they will have to pay... Let's dream of a day when Constantinople will be "cleaned up" and returned to Europe.

Thursday, 25 January 2018

Droit de Sol - Droit de Sang

In summer 2014, during the Football World Cup (I don't give a shit about football, by the way), one evening I heard tons of noise on the street, like a celebration, mainly cars with their claxons. It was odd, France was not playing that day, so no victory to celebrate in principle. I looked through the window and saw cars with people shouting with half of their bodies out of the cars waving Algerian flags. Yep, Algeria had won that day and they were cellebrating it. I found it funny but interesting, I thought those French people of Algerian descent would have a mixed identity, it seemed normal to me. The next day I read something not so funny in the newspaper regarding this "Maghrebian partying". In the Quartiers Sensibles this cellebrations involved burning cars (not sure if these fires were accompanied by stoning the police, the firefigthers, some buses... as it happens lately in Halloween, New Year's Eve... in these neighbourhoods). Retarded, medieval beasts have odd ways to express their happiness... but anyway I think I didn't pay much attention to it, at that point I thought multicultural France was working as I dreamed it to work, and not as the growing mess of the last decade(s)...

Over the next years I've become more and more aware of how one kind of immigration has enriched this country in so many aspects, but another part of the immigration (particularly their children), is destroying this society. I guess you don't need more explanations, but yes, sure I'm talking about one (sizeable) part of the Muslims and people of Maghrebian descent... It's not only the Islamist scum or the dealers and criminals, it's that as the basis of it, these people that have been born and raised in France and enjoyed all the opportunities (well, only a few, others like education they decided to reject them) that this country has to offer, don't consider themselves French, and not because they are Anarchists, but because they consider themselves Moroccans, Algerians, Tunisians...

If you don't know what Jus Soli and Jus Sanguinis mean, you should read the articles, but let's say that the nationality laws of advanced countries (like France or indeed Spain) apply a mix of both. Basically any progressist person should advocate for applying some sort of "intelligent" Jus Soli to "foreigners". I mean:

  • If you are born in one country of foreign parents, but this is not accidental (a temporal trip), but your parents have been living in the country and plan to continue to live in the country with you, and they (and you) are integrated in the country, you should be granted the nationality almost automatically.
  • If you migrate to one country, live and work there for a few years, and you demonstrate that you have integrated in the local culture, you should get the nationality without any problem, and get the same rights (and duties) as anyone which grand-grand-grand... parents had been born in the country

For ethnic nationalists, far-right idiots and so on, things are very different... they consider that your right to nationality depends only on your ancestors... fucking assholes. It's a form of predestination. Basically your ancestors determine where you can live, where you can feel to belong to, it's a denial of human individual freedom and evolution.

When someone that has been born and lived in this country all his life considers that his contry is the one where his parents (or maybe not even them, just his grandparents) were born, a country where maybe he goes once per year... it seems crazy to me. It also seems like a disgusting display of ingratitude. Your parents or grandparents moved away from their poor countries to pursue a better life here, and this society accepted them and gave them and their descendants full rights, but you despite this society by adhering to that other "faraway" country...

This kind of ingratitude feels like a bit offensive, and indeed it makes me wonder why these people don't move to that other country that is so fascinating and they love so much... well, do you really need an answer? But well, to a certain extent one could bear with it. What is way beyond unacceptable is when this attitude leads to mobs to riot on the street and loot shops, as idiots of Moroccan descent did in Brussels and Paris last November...

In any case, this situation where someone fully identifies with the country of his ancestors rather than with the country where he has lived so far, seems to me like a pure form of Jus Sanguinis and of ethnical/genetic nationalism. So in the end all these people look to me like far-right militants. How odd that the antifascist left only fights the European far-right and not the maghrebian far-right...

Thursday, 18 January 2018

Juger les Djihadistes

The excellent editorial by Riss (La-bas si j'y suis) in last week's Charlie Hebdo reminded me of another stupid debate happening now in France. It deals with whether the Yihadists of French nationality that have been captured in Syria or Irak should be judged in those countries or should be brought back to France to judge them here. The idea is that a French citizen that joins a terrorist organization is already committing a crime under the French law and hence can be judged in France. OK, that sounds correct, but as he has committed crimes (murdering, raping...) in another country for sure the other country has the right to judge him according to its laws. This criminal is already arrested in the country where he has conducted his worst crimes, so for sure he has to be judged there. If hopefully he is sentenced to capital punishment or a life sentence, that's all, if he were setenced to less than that then it would make sense that once he has finished his sentence he is brought to France and judged and condemned in France. Well, indeed that would be a very bad idea, because he would live a few years in prison at the expense of the French tax-payer and then he would be free in our soil, willing to radicalise others and attack again... The best option would be to deprive these beasts of the French nationality and never let them back.

Unfortunately, those who want to bring these bastards back in France have something completely different in mind. They want to bring them back in France now, so that they can scape the sentence in Irak/Syria (where hopefully and most likely they will be executed as they deserve) and be judged by the soft French laws that will just sentence them to staying a few years in a luxury prison where they will be able to radicalise other immates... This is what some stupid "Human Rights" organizations (you can read what I think about these "humans" here), families, Islamist scum and the the criminals themselves think.

So these criminals that hate France and the French society so much, that do not recognize its institutions and have pissed and shit on them for years (first as delinquents in their "quartiers", then trying to spread the Islamist disease, and then by "representing this country" killing innocents and raping...) now suddenly want to return "home" and adhere to the French law... obviously because they want to scape death and get the soft sentence that the lax and weak French Justice system (or any other Western European System) would give them... In the end these pieces of shit are neither so "valerous" as they claim or so "crazy" as the IslamoGauche tries to sell us as a way to excuse Islam... I don't know what "the book" says about it, but maybe being captured and executed does not grant these "warriors" with the promised 72 virgins...