not to be equated with “contrary to the law”, but must be interpreted more broadly to include elements of inappropriateness, injustice, lack of predictability and due process of law. 495 356. The Inter-American Court has indicated that, without prejudice to the legality of a detention, in each case an analysis must be made of the compatibility of the legislation with the Convention, on the understanding that the law and its application must respect the requirements listed below to ensure that the deprivation of liberty is not arbitrary: 496 i) that the purpose of the measures that deprive or restrict liberty is compatible with the Convention; ii) that the measures adopted are suitable to achieve the desired purpose; iii) that they are necessary, in the sense that they are absolutely essential to achieve the desired purpose and that, among all possible measures, there is no less burdensome measure in relation to the right involved, that would be as suitable to achieve the proposed objective; for this reason, the Court has indicated that the right to personal liberty means that any limitation of this right must be exceptional, 497 and iv) that the measures are strictly proportionate, 498 so that the sacrifice inherent to the restriction of the right to liberty is not exaggerated or excessive in relation to the advantages obtained by such restriction and the fulfilment of the purpose pursued. 499 Any restriction of liberty that is not based on a sufficient justification that meets the above criteria will be arbitrary and will therefore violate Article 7(3) of the Convention. 500 357. In cases involving pretrial detention within a criminal proceeding, the Court has indicated that the decision to deprive the defendant of his liberty cannot be based on ‘generalpreventive or special-preventive’ objectives attributable to the penalty, but can only be based on a legitimate purpose, namely: to ensure that the accused does not interfere with the development of the proceedings or evade the action of justice. 501 It has also emphasized that procedural risk cannot be presumed, but must be verified in each case, based on the objective and proven circumstances of the specific case. 358. The Court has likewise established that the unpredictability of deprivation of liberty may make it arbitrary (supra para. 355). On this point, the Court has indicated that the law on which the deprivation of personal liberty is based must establish as specifically as possible and “beforehand” the “reasons” for and “conditions” of the deprivation of physical liberty. 502 Compliance with these requirements is designed to protect the individual from arbitrary detention. 503 Among the conditions stated for deprivation of liberty, the applicable law should Cf. Case of Chaparro Álvarez and Lapo Íñiguez v. Ecuador, supra, para. 92, and Case of Yarce et al. v. Colombia, supra, para. 140. 496 Cf. Case of Chaparro Álvarez and Lapo Íñiguez v. Ecuador, supra, para. 93, and Case of Wong Ho Wing v. Peru. Preliminary objections, merits, reparations and costs. Judgment of June 30, 2015 Series C No. 297, para. 248. 497 Cf. Case of Ricardo Canese v. Paraguay. Merits, reparations and costs. Judgment of August 31, 2004. Series C No. 111, Para. 129, and Case of Wong Ho Wing v. Peru, supra, para. 248. 498 Cf. Case of Ricardo Canese v. Paraguay, supra, para. 129, and Case of Wong Ho Wing v. Peru, para. 248. 499 Cf. Case of Chaparro Álvarez and Lapo Íñiguez. v. Ecuador, supra, para. 93, and Case of Wong Ho Wing v. Peru, supra, para. 248. 500 Cf. Case of García Asto and Ramírez Rojas v. Peru. Judgment of November 25, 2005. Series C No. 137, para. 128, and Case of Yarce et al. v. Colombia, para. 158. 501 Cf. Case of Suárez Rosero v. Ecuador. Merits. Judgment of November 12, 1997, para. 77, and Case of Wong Ho Wing v. Peru, supra, para. 250. 502 Cf. Case of Chaparro Álvarez and Lapo Íñiguez v. Ecuador, supra, para. 57, and Case of Wong Ho Wing v. Peru, supra, para. 254. 503 Cf. Case of Wong Ho Wing v. Peru, supra, para. 254. Similarly, the European Court has established that the protection of the individual from arbitrariness implies that the application of the law must be sufficiently precise and predictable. Cf. ECHR, Case Ryabikin v. Russia, No. 8320/04. Judgment of June 19, 2008, para. 127; Case Baranowski v. Poland, No. 28358/95. Judgment of March 28, 2000, paras. 50 to 52; Case of Khudoyorov v. Russia, No. 6847/02. Judgment of November 8, 2005, para. 125; Case of Calovskis v. Latvia, No. 22205/13. Judgment of July 24, 2014, para. 182; Case of L.M. v. Slovenia, No. 32863/05. Judgment of June 12, 2014, paras. 121 and 122. 495 115

Seleccionar párrafo de destino3